Closed davekinkead closed 11 years ago
Ok, so I've added this as a module Tire::Model::DynamicPersistence which needs to be included after persistence, ie:
include Tire::Model::Persistence include Tire::Model::DynamicPersistence
Readme, tests, & updated gemspec included.
In addition to tests for the new functionality, I've also included all the persistence_model_tests from Tire to ensure no legacy behaviour breaks. I did have to change one test (see inline comments) but behaviour is still compatible. https://github.com/davekinkead/tire-contrib/blob/master/test/dynamic_persistence/model_persistence_test.rb#L261
Cheers,
Dave
Hi Dave, I've removed the ported tests, since it would be too hard to maintain them in sync, and retouched it a bit. Thanks!
Ok, so I've added this as a module Tire::Model::DynamicPersistence which needs to be included after persistence, ie:
Readme, tests, & updated gemspec included.
In addition to tests for the new functionality, I've also included all the persistence_model_tests from Tire to ensure no legacy behaviour breaks. I did have to change one test (see inline comments) but behaviour is still compatible. https://github.com/davekinkead/tire-contrib/blob/master/test/dynamic_persistence/model_persistence_test.rb#L261
Cheers,
Dave