Move betterproto/tests → tests

This commit is contained in:
Arun Babu Neelicattu 2020-07-10 13:45:52 +02:00 committed by Bouke Versteegh
parent 8864f4fdbd
commit cebf9176a3
112 changed files with 27 additions and 27 deletions

2
.gitignore vendored
View File

@ -6,7 +6,7 @@
.pytest_cache .pytest_cache
.python-version .python-version
build/ build/
betterproto/tests/output_* tests/output_*
**/__pycache__ **/__pycache__
dist dist
**/*.egg-info **/*.egg-info

View File

@ -6,7 +6,7 @@ help: ## - Show this help.
# Dev workflow tasks # Dev workflow tasks
generate: ## - Generate test cases (do this once before running test) generate: ## - Generate test cases (do this once before running test)
poetry run ./betterproto/tests/generate.py poetry run ./tests/generate.py
test: ## - Run tests test: ## - Run tests
poetry run pytest --cov betterproto poetry run pytest --cov betterproto
@ -23,7 +23,7 @@ clean: ## - Clean out generated files from the workspace
.pytest_cache \ .pytest_cache \
dist \ dist \
**/__pycache__ \ **/__pycache__ \
betterproto/tests/output_* tests/output_*
# Manual testing # Manual testing

View File

@ -50,7 +50,7 @@ You can add multiple `.proto` files to the test case, as long as one file matche
`test_<name>.py` &mdash; *Custom test to validate specific aspects of the generated class* `test_<name>.py` &mdash; *Custom test to validate specific aspects of the generated class*
```python ```python
from betterproto.tests.output_betterproto.bool.bool import Test from tests.output_betterproto.bool.bool import Test
def test_value(): def test_value():
message = Test() message = Test()

View File

@ -6,7 +6,7 @@ import shutil
import sys import sys
from typing import Set from typing import Set
from betterproto.tests.util import ( from tests.util import (
get_directories, get_directories,
inputs_path, inputs_path,
output_path_betterproto, output_path_betterproto,

View File

@ -1,5 +1,5 @@
import asyncio import asyncio
from betterproto.tests.output_betterproto.service.service import ( from tests.output_betterproto.service.service import (
DoThingResponse, DoThingResponse,
DoThingRequest, DoThingRequest,
GetThingRequest, GetThingRequest,

View File

@ -1,4 +1,4 @@
from betterproto.tests.output_betterproto.service.service import ( from tests.output_betterproto.service.service import (
DoThingResponse, DoThingResponse,
DoThingRequest, DoThingRequest,
GetThingRequest, GetThingRequest,

View File

@ -1,4 +1,4 @@
from betterproto.tests.output_betterproto.bool import Test from tests.output_betterproto.bool import Test
def test_value(): def test_value():

View File

@ -1,5 +1,5 @@
import betterproto.tests.output_betterproto.casing as casing import tests.output_betterproto.casing as casing
from betterproto.tests.output_betterproto.casing import Test from tests.output_betterproto.casing import Test
def test_message_attributes(): def test_message_attributes():

View File

@ -1,4 +1,4 @@
from betterproto.tests.output_betterproto.casing_message_field_uppercase import Test from tests.output_betterproto.casing_message_field_uppercase import Test
def test_message_casing(): def test_message_casing():

View File

@ -3,8 +3,8 @@ from typing import Any, Callable, Optional
import betterproto.lib.google.protobuf as protobuf import betterproto.lib.google.protobuf as protobuf
import pytest import pytest
from betterproto.tests.mocks import MockChannel from tests.mocks import MockChannel
from betterproto.tests.output_betterproto.googletypes_response import TestStub from tests.output_betterproto.googletypes_response import TestStub
test_cases = [ test_cases = [
(TestStub.get_double, protobuf.DoubleValue, 2.5), (TestStub.get_double, protobuf.DoubleValue, 2.5),

View File

@ -1,7 +1,7 @@
import pytest import pytest
from betterproto.tests.mocks import MockChannel from tests.mocks import MockChannel
from betterproto.tests.output_betterproto.googletypes_response_embedded import ( from tests.output_betterproto.googletypes_response_embedded import (
Output, Output,
TestStub, TestStub,
) )

View File

@ -1,7 +1,7 @@
import pytest import pytest
from betterproto.tests.mocks import MockChannel from tests.mocks import MockChannel
from betterproto.tests.output_betterproto.import_service_input_message import ( from tests.output_betterproto.import_service_input_message import (
RequestResponse, RequestResponse,
TestStub, TestStub,
) )

View File

@ -1,6 +1,6 @@
import betterproto import betterproto
from betterproto.tests.output_betterproto.oneof import Test from tests.output_betterproto.oneof import Test
from betterproto.tests.util import get_test_case_json_data from tests.util import get_test_case_json_data
def test_which_count(): def test_which_count():

View File

@ -1,12 +1,12 @@
import pytest import pytest
import betterproto import betterproto
from betterproto.tests.output_betterproto.oneof_enum import ( from tests.output_betterproto.oneof_enum import (
Move, Move,
Signal, Signal,
Test, Test,
) )
from betterproto.tests.util import get_test_case_json_data from tests.util import get_test_case_json_data
@pytest.mark.xfail @pytest.mark.xfail

Some files were not shown because too many files have changed in this diff Show More