formly-js / angular-formly

JavaScript powered forms for AngularJS
http://docs.angular-formly.com
MIT License
2.22k stars 405 forks source link

test(formly-field): should run field expressions when form is initialised #603

Closed BarryThePenguin closed 8 years ago

BarryThePenguin commented 8 years ago

Skipped test for #602

codecov-io commented 8 years ago

Current coverage is 95.88%

Merging #603 into master will not affect coverage as of 991c2fe

@@            master    #603   diff @@
======================================
  Files           16      16       
  Stmts         1117    1117       
  Branches         0       0       
  Methods          0       0       
======================================
  Hit           1071    1071       
  Partial          0       0       
  Missed          46      46       

Review entire Coverage Diff as of 991c2fe


Uncovered Suggestions

  1. +0.35% via ...alidationMessages.js#25...28
  2. +0.27% via src/test.utils.js#38...40
  3. +0.27% via ...s/formlyUsability.js#18...20
  4. See 7 more...

Powered by Codecov. Updated on successful CI builds.

kentcdodds commented 8 years ago

Just to clarify, this is intended to only run the hide expression right? Other expressionProperties won't work until the field itself is compiled.

kentcdodds commented 8 years ago

Based on the test, I'm guessing that is the case. Thanks!

BarryThePenguin commented 8 years ago

This is just for hide expression yeah...

Would it be possible to run expressionProperties after the field is compiled? That's what I'm trying to figure out

kentcdodds commented 8 years ago

Yes, go to the link function where we're chaining the steps of the promises to compile the template and just add another step or add to an existing step