Skip to content

Commit

Permalink
test update
Browse files Browse the repository at this point in the history
  • Loading branch information
nawaz1991 committed Dec 9, 2023
1 parent 9b6b553 commit a2e2af5
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 18 deletions.
28 changes: 14 additions & 14 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,20 @@ module = ["ninja"]
ignore_missing_imports = true


#[tool.pytest.ini_options]
#minversion = "6.0"
#addopts = ["-ra", "--showlocals", "--strict-markers", "--strict-config"]
#xfail_strict = true
#filterwarnings = [
# "error",
# "ignore:(ast.Str|Attribute s|ast.NameConstant|ast.Num) is deprecated:DeprecationWarning:_pytest",
#]
#testpaths = ["tests"]
#
#[tool.cibuildwheel]
#test-command = "pytest {project}/tests"
#test-extras = ["test"]
#test-skip = ["*universal2:arm64"]
[tool.pytest.ini_options]
minversion = "6.0"
addopts = ["-ra", "--showlocals", "--strict-markers", "--strict-config"]
xfail_strict = true
filterwarnings = [
"error",
"ignore:(ast.Str|Attribute s|ast.NameConstant|ast.Num) is deprecated:DeprecationWarning:_pytest",
]
testpaths = ["tests"]

[tool.cibuildwheel]
test-command = "pytest {project}/tests"
test-extras = ["test"]
test-skip = ["*universal2:arm64"]
# Setuptools bug causes collision between pypy and cpython artifacts
before-build = "rm -rf {project}/build"

Expand Down
4 changes: 0 additions & 4 deletions tests/test.py

This file was deleted.

8 changes: 8 additions & 0 deletions tests/test_basic.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import oasvalidator


def test_validate():
validators = oasvalidator.init("thirdparty/cpp-oasvalidator/data/openAPI_example.json")
error, error_msg = validators.validate_route("GET", "/v1/pets")
assert error == oasvalidator.ValidationError.INVALID_ROUTE

0 comments on commit a2e2af5

Please sign in to comment.