mbest / knockout

My enhancements to Knockout
35 stars 4 forks source link

Set a new binding provider before each test to prevent possibility of in... #15

Closed gilesbradshaw closed 12 years ago

gilesbradshaw commented 12 years ago

...terference between tests

eg with the bindings cache

I think this makes sense doesn't it? as the cache (and anything else) would remain in the binding provider between tests. I know the whole point of the cache is that this shouldn't matter but it seems wrong that it is full of stuff from other tests

mbest commented 12 years ago

This is a good idea. But your templatingBehaviors.js includes a lot of formatting changes that I don't want to merge. So I'll just put in your changes myself.

mbest commented 12 years ago

I decided to just call ko.bindingProvider.instance.clearCache instead of creating a new instance.