Testing suite limitations

So far I have found that the testing suite is fairly rigid. With a few projects, I satisfied all user stories, but failed some tests. In particular with the drum machine project, I added code to animate a button when a key is pressed, but that caused a test to fail. I removed the code and passed all tests, but the project is slightly less functional.

I get meeting user stories. And I meet them. I am saying that you can satisfy the user stories in some instances and still fail some of the tests.

For instance:

The Drum Machine Project All user stories satisfied. All tests passed. Key presses do not animate the buttons.

The Drum Machine Project II All user stories satisfied. One test failed with the following error: Uncaught TypeError: Cannot read property ‘classList’ of null (pen.js:112) The code adds a class to animate the associated button. Buttons animated on keypress.

Thanks for the feedback. I have learned a bit more about how react handles things like the audio element. I have refactored so that there is no direct DOM manipulation. It is however much more complex. I feel this is a tad overkill, but that is perhaps just me.