Here are the examples of the python api requests.post.when.called_with.should.throw taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
4 Examples
3
Example 1
View license@mock_ec2 def test_not_implemented_method(): requests.post.when.called_with( "https://ec2.us-east-1.amazonaws.com/", data={'Action': ['foobar']} ).should.throw(NotImplementedError)
0
Example 2
View license@mock_s3 def test_key_method_not_implemented(): requests.post.when.called_with("https://foobar.s3.amazonaws.com/foo").should.throw(NotImplementedError)
0
Example 3
View license@mock_s3bucket_path def test_key_method_not_implemented(): requests.post.when.called_with("https://s3.amazonaws.com/foobar/foo").should.throw(NotImplementedError)
0
Example 4
View license@mock_sqs def test_sqs_method_not_implemented(): requests.post.when.called_with("https://sqs.amazonaws.com/?Action=[foobar]").should.throw(NotImplementedError)