Skip to content

Added Tests for revise! and fixed a few errors #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Oct 3, 2013

Conversation

gautamrege
Copy link
Collaborator

revise! was failing and there were not test cases for it.. added them

Also a few errors fixed:

  • clear_persistence option not required
  • Factory#build should not specify attribute protection.

Passing without_protected: true is no longer valid. Mongoid now
relies on ForbiddenAttributesProtection for this.

see: mongoid/mongoid@33bd65d
Even if the document has not changed, revise! should
create a version
@simi
Copy link
Owner

simi commented Aug 19, 2013

Thanks for fixes @gautamrege! Some tests are failing now, I'll try to figure out why. 😻

@gautamrege
Copy link
Collaborator Author

There are couple of tests (un-related to my commits) that are failing on local..pushed the changes nevertheless 😈 These were the tests when not using default database. am investigating.

@simi
Copy link
Owner

simi commented Aug 19, 2013

@gautamrege I think it is related to mongoid/mongoid@0a486e0.

@simi
Copy link
Owner

simi commented Sep 4, 2013

@gautamrege any news?

@gautamrege
Copy link
Collaborator Author

Heh! Got stuck with some work - looking into this now.

Also removed the monkey patch for collection as mongoid now picks up
the persistence options properly in the session.

Added the with scope when we search for revisions!
@gautamrege
Copy link
Collaborator Author

@simi This should fix things. Let me know your thoughts.

@simi
Copy link
Owner

simi commented Oct 3, 2013

@gautamrege sorry. I missed your comment. Looks good! Awesome work @gautamrege.

simi added a commit that referenced this pull request Oct 3, 2013
Added Tests for revise! and fixed a few errors
@simi simi merged commit 3defb08 into simi:master Oct 3, 2013
@gautamrege
Copy link
Collaborator Author

cool!

@simi
Copy link
Owner

simi commented Oct 3, 2013

I added you into contributors list. I'll give you rubygems access once I'll release this if you're interested.

@gautamrege
Copy link
Collaborator Author

Awesome - I can surely help in supporting this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants