Number of documents in movies collection - fixed

The number of movies in the imported collection is 23539. I used both mongorestore and load sample data set. For this reason, my unit test fails for Kosovo=2. Same for the getMoviesByCountry.
I can see that other people reported the same issue in other courses (M103, M220JS, M220J).
I downloaded the latest handout from the left side on the course’s web page and have the same problem.
The projection fails for Australia:

I believe this is the number the test is looking for, no? I believe that is what the issue is. When I went through the M220JS my test was looking for 45993 now the newer version of these projects are looking for 23539.

If I have misunderstood please I apologize.

I might be wrong, but the source code that I got is still checking for the counts from the full set (45993). For example, the unit test expects 2 movies from Kosovo, but I checked in 3 different ways: java code/mongo shell/Compass and there is no movie from Kosovo in the reduced set. Same for the Ticket for Projection, apparently it expects to find 710 movies from Australia, but the query returns only 262.

This is likely correct. And you mentioned that you downloaded the version in the Handouts section. I do not have access to the Java course as I took the JS version so one of the moderators will have to link you to the correct zip file for Java.

Please ignore my post, there was an error in my code. Both the unit test and the projection ticket are successful with the new data set.

1 Like