Skip to content

Commit bdaa7aa

Browse files
committed
Issues fixed in tests
1 parent f3a0421 commit bdaa7aa

File tree

7 files changed

+181
-169
lines changed

7 files changed

+181
-169
lines changed

delta_backend/Makefile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,16 @@ package: build
88
test:
99
python -m unittest
1010

11+
check-conversion:
12+
python tests/check_conversion.py
13+
14+
coverage-run:
15+
coverage run -m unittest discover -v
16+
17+
coverage-report:
18+
coverage report -m
19+
20+
coverage-html:
21+
coverage html
22+
1123
.PHONY: build package

delta_backend/poetry.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

delta_backend/pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ boto3 = "~1.26.90"
1414
mypy-boto3-dynamodb = "^1.26.164"
1515
moto = "~4.2.11"
1616
python-stdnum = "^1.20"
17+
coverage = "^7.8.0"
1718

1819
[tool.poetry.group.dev.dependencies]
1920
coverage = "^7.8.0"

delta_backend/tests/sample_data/__init__.py

Whitespace-only changes.

delta_backend/tests/sample_data/test_resource_data.py

Lines changed: 0 additions & 164 deletions
This file was deleted.

delta_backend/tests/test_delta.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
os.environ["SOURCE"] = "my_source"
1212

1313
from delta import send_message, handler # Import after setting environment variables
14-
from sample_data.test_resource_data import get_test_data_resource
14+
from tests.utils_for_converter_tests import ValuesForTests
1515

1616
class DeltaTestCase(unittest.TestCase):
1717

@@ -76,7 +76,7 @@ def get_event_record(pk, event_name="INSERT", operation="CREATE", supplier="EMIS
7676
"Operation": {"S": operation},
7777
"SupplierSystem": {"S": supplier},
7878
"Resource": {
79-
"S": json.dumps(get_test_data_resource()),
79+
"S": json.dumps(ValuesForTests.get_test_data_resource()),
8080
}
8181
}
8282
}
@@ -91,7 +91,7 @@ def get_event_record(pk, event_name="INSERT", operation="CREATE", supplier="EMIS
9191
"PatientSK": {"S": pk},
9292
"SupplierSystem": {"S": "EMIS"},
9393
"Resource": {
94-
"S": json.dumps(get_test_data_resource()),
94+
"S": json.dumps(ValuesForTests.get_test_data_resource()),
9595
}
9696
}
9797
}

0 commit comments

Comments
 (0)