Front End Development Libraries Projects - Build a Drum Machine

Tell us what’s happening:
Describe your issue in detail here.
I followed the user stories and i got all of the functionality that was required. I tried to test using the test suite that is provided but two of the test cases are not passing and i don’t know why. The test that checks if sound on click is played, and the test that checks if sound on key press is played. I don’t know why the test suite is failing I’ve been looking at this for hours.

Your code so far

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:106.0) Gecko/20100101 Firefox/106.0

Challenge: Front End Development Libraries Projects - Build a Drum Machine

Link to the challenge:

let clip = new Audio(
  document.getElementById(element).getAttribute("src")
);

This is the reason you aren’t passing those tests. The tests don’t want you do create a new Audio object. They want you to call play on the audio element itself.

1 Like