Skip to content
This repository was archived by the owner on Dec 22, 2021. It is now read-only.

Conversation

@nfg
Copy link
Contributor

@nfg nfg commented Jan 13, 2016

Hello! I wrote some unit test code like

my $res = $collection->insert_many(\@test_data);
is($res->inserted_count, 3, 'Inserted three records');

And, weirdly, got undef back. According to $res->inserted, I successfully inserted three records. I looked at the code, and couldn't find anywhere that "inserted_count" was actually being set. And so, voila.

Let me know if there's anything I should change.

Cheers!

@xdg
Copy link
Contributor

xdg commented Jan 14, 2016

Thanks! I'll check it out tomorrow.

@xdg xdg merged commit f371b43 into mongodb-labs:master Jan 14, 2016
@xdg
Copy link
Contributor

xdg commented Jan 14, 2016

Great catch and thank you for the PR! I've merged it to master and will
backport it for a 1.2.x bugfix release at the end of the current sprint.

@nfg
Copy link
Contributor Author

nfg commented Jan 14, 2016

That's awesome, thanks! :-D

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants