1
0
mirror of https://github.com/kevin1024/vcrpy.git synced 2025-12-08 16:53:23 +00:00

Added unit test for matcher 'method'

This commit is contained in:
Max Shytikov
2014-04-01 00:11:55 +02:00
parent 16c6135387
commit cd32f5114c

View File

@@ -0,0 +1,13 @@
from vcr import matchers
from vcr import request
def test_method():
req_get = request.Request('http', 'google.com', 80, 'GET', '/', '', {})
assert True == matchers.method(req_get, req_get)
req_get1 = request.Request('https', 'httpbin.org', 80, 'GET', '/', '', {})
assert True == matchers.method(req_get, req_get1)
req_post = request.Request('http', 'google.com', 80, 'POST', '/', '', {})
assert False == matchers.method(req_get, req_post)