def test_swagger_schema_for_request_not_found(schema):
    """Tests that validators_for_request() raises exceptions when
    a path is not found.
    """
    # There exists a GET and POST for this endpoint. We should be able to call
    # either and have them pass validation.
    with pytest.raises(PathNotMatchedError) as excinfo:
        schema.validators_for_request(
            request=mock.Mock(
                path="/does_not_exist",
                method="GET"
            ),
        )
    assert str(excinfo) in '/does_not_exist'
    assert 'Could not find ' in str(excinfo)
dataset/ETHPy150Open striglia/pyramid_swagger/tests/model_test.py/test_swagger_schema_for_request_not_found/swapped operands of `in`