@bdd.then(bdd.parsers.parse('The requests should be:\n{pages}'))
def list_of_requests(httpbin, pages):
 expected_requests = [httpbin.ExpectedRequest('GET', ('/' + path.strip())) for path in pages.split('\n')]
 actual_requests = httpbin.get_requests()
 assert (actual_requests == expected_requests)

@ bdd . then ( bdd . parsers . parse ( 'The requests should be:\n{pages}' ) ) def list_of_requests ( httpbin , pages ) : expected_requests = [ httpbin . ExpectedRequest ( 'GET' , ( '/' + path . strip ( ) ) ) for path in pages . split ( '\n' ) ] actual_requests = httpbin . get_requests ( ) assert ( actual_requests == expected_requests )
make sure the given requests were done from the webserver .