Hi, Now that the test skeleton is in the repository (the codename-simplify branch), it would be very helpful if more people could contribute with tests. The testing code is quite simple, here's an example from the person main details page tests:
def test_name_should_be_canonical(person_main_details): page = person_main_details('keanu_reeves') data = parser.parse(page)['data'] assert data['name'] == 'Reeves, Keanu' The body of every test function is like that. Get the page, run through the parser, check the result. I have written the functions for getting the movie combined details page and the person main details page. I will add the other types of pages soon or I can add one when anyone needs it. The current tests are here: https://github.com/alberanid/imdbpy/tree/codename-simplify/tests What needs to be done is as follows: 1. Select something that hasn't been tested yet. 2. Select a person (or movie, or company etc) page that can be used to test it. 3. If not already there, add its IMDb id to the relevant dictionary in the conftest.py file (MOVIES, PEOPLE). 4. Figure out the name of the key in the result and write an assert to check for the correct value. Having more tests would increase our confidence in the parsers, especially after the port to Python3. Any contributions would be greatly appreciated. Cheers -- Turgut ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Imdbpy-help mailing list Imdbpy-help@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/imdbpy-help