Exemplo n.º 1
0
 def list_courses(self):
     self.browser.open(self.base_url)
     response = self.browser.response.text
     courses = helpers.get_courses_from_json(response)
     return courses
Exemplo n.º 2
0
def test_courses_from_json():
    course_json = '{"my_courses": [{"course_path": "/courses/creative-applications-of-deep-learning-with-tensorflow-i"}]}'
    courses = helpers.get_courses_from_json(course_json)
    assert courses == [
        "/courses/creative-applications-of-deep-learning-with-tensorflow-i"
    ]
Exemplo n.º 3
0
def test_courses_from_json():
    course_json = '{"courses": [{"course_path": "/courses/creative-applications-of-deep-learning-with-tensorflow-i"}]}'
    courses = helpers.get_courses_from_json(course_json)
    assert courses == ["/courses/creative-applications-of-deep-learning-with-tensorflow-i"]