dkubb changed the topic of #datamapper to: Datamapper v1.2.0 | Mailing List: http://is.gd/aa9D | Logs: http://is.gd/qWAL7V | DataMapper 2 Renamed to ROM, see #rom-rb for development
<jordanyee>
Does any one know what the proper term for doing this is?
<jordanyee>
I'm just wondering if there's a proper technical name for doing it all in one line of code
<jordanyee>
Oh okay, cool, night!
<mbj>
jordanyee: deep mass assignment with coercion to associated resource?
<mbj>
technical term idea :D
<mbj>
cu
mbj has quit [Client Quit]
<dkubb>
yeah, I added that but I don't recall ever giving it a name
<dkubb>
it also works with the same syntax for querying
<dkubb>
so like .all and .first
<jordanyee>
Oh awesome. Yeah, it's a great feature to cut down on the amount of code needed
<jordanyee>
I've found that when using it though, validation doesn't seem to happen on associated models
<dkubb>
yeah, I'm not sure if dm-validations would recurse or not
<jordanyee>
In the nested model, a property with :required => true, happily gets created with a null value if a nil is passed
<jordanyee>
Oh okay
<dkubb>
I would dig into dm-validations and see if there's something you can use. I believe there is something that allows you to validate the associations, but I can't recall
<jordanyee>
Alright, I'll dig into that
g0bl1n has quit [Ping timeout: 246 seconds]
<jordanyee>
dkubb: Looks like there's an open pull request that adds validation of associations
<jordanyee>
Is there anything I can do to help that get merged?
brianpWins has quit [Quit: brianpWins]
<dkubb>
jordanyee: if you want to create a new PR with those changes and make sure it applies against release-1.2, and that travis passes, I'll merge it
<dkubb>
you may need to bug me a bit on IRC though because I don't really monitor the DM issue tracker anymore
<jordanyee>
dkubb: I'm new to contributing to a large project like this. Could you point me to a guide on how I would test that a PR works against the current 1.2 release? I also haven't worked with travis before... :S
<dkubb>
jordanyee: what you can do is pull down the current release 1.2 branch, and then add xshay's branch as a remote via git, and merge it into the release 1.2 branch, then run the tests locally
<dkubb>
jordanyee: assuming they pass, fork dm-validations on github, log into travis with your github account and add the repo to the list of repos you want tested. then push your branch to your github fork. the tests should be triggered
<dkubb>
assuming it all passes, open up a PR and then ping me here
<dkubb>
it sounds worse than I've explained it ;)
<dkubb>
er I mean, it sounds bad, but it's not really too bad
<dkubb>
it requires a bit of git knowledge. you'll need to learn how to push/pull/add remotes/merge
<jordanyee>
Okay, it took a few reads through, but I think I can handle that
<jordanyee>
Here goes...
siplux has joined #datamapper
brianpWins has joined #datamapper
<jordanyee>
dkubb: I've got the branches merged -- had to do a bit of research.
<jordanyee>
What command do I use to run the tests? I'm not familiar with the way the tests are set up here
<jordanyee>
It should be rake spec, right?
<jordanyee>
I keep getting this error despite having installed RSpec
<jordanyee>
rspec is not available. In order to run spec, you must: gem install rspec
<jordanyee>
Oh I have RSpec 2.14 installed instead of 1.3.2
lfox has quit [Quit: ZZZzzz…]
zombor has quit [Remote host closed the connection]
<jordanyee>
dkubb: Got everything sorted, just waiting for Travis to run the tests. I'll ping you when it's good
<jordanyee>
Hope I did everything correctly. Let me know if you need me to make any fixes
<dkubb>
jordanyee: there's two things I noticed
<dkubb>
jordanyee: note that you're asking me to merge it into master, but you want to have it merged into release-1.2
<dkubb>
jordanyee: the other thing is that travis didn't run your test, so I think you need to go into travis to set your fork as testable.. from your account settings you run the "sync" command, then turn on travis for the repo
zombor has joined #datamapper
<dkubb>
jordanyee: oh, one other thing, I presume you added your branch to your app's Gemfile to confirm the fix actually solves your problem?
<dkubb>
it's one thing to use an existing PR, and xshay's stuff is pretty solid, but you may want to confirm it works for your case
<jordanyee>
Oh no, I haven't actually
zombor has quit [Ping timeout: 250 seconds]
<jordanyee>
Okay, well, first things first, I'll fix the pull request to release-1.2 when I resubmit it
<dkubb>
cool
<jordanyee>
Second, I think Travis did run the test
<dkubb>
yeah, release-1.2 is what we're maintaining. it'll take some effort to reconcile the work on the master branch wit the stable stuff
<dkubb>
oh yeah? I guess I just expected the little icon next to the commit in the PR