Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
I got stuck with this problem too. I was using "hash.delete_if" – when I switched to the non-destructive "hash.reject" it worked fine.
It might be worth adding a line to the kata description warning people that the input hash should not be messed with.
This comment is hidden because it contains spoiler information about the solution
After forfeiting my eligibility to look at the test cases ;-; I found out why I had the issue - I modified the original hash using bang (!) methods
When I left the hash "as is", I could pass the test.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
I've being experiencing the same issue
Hey shotop, what do you mean by basic debuggging? I couldn't find what's being passed in.
Did you check the network and xhr files ?(Also getting an error on the third)
Given that each and count have already been implemented, you shouldn't need to fully define the Bag class or its initialize method. These should already exist. Your implementation should focus strictly on every? and any further helper methods you need to create for that to work.
The message "should execute the block for each item in the bag. why are you messing with this method? work on #every? instead" isn't indicative of an error. It's the name of that particular test, for whatever reason.
The NoMethodErrors suggest that you are somehow passing a nil into the tests. The tests only call each on a bag object and this test passes with the default implementation, so a change you've made seems to have broken each for the Bag class.