aboutsummaryrefslogtreecommitdiff
path: root/tests/managers/test_hit.py
diff options
context:
space:
mode:
authorMax Nanis2026-02-26 20:29:41 -0500
committerMax Nanis2026-02-26 20:29:41 -0500
commitaf66829e26cb05f182bef36ac06d58c7baa0ec1e (patch)
tree2848a9223e7d4d680f3e93fc8dfcc7545f716abd /tests/managers/test_hit.py
parent0bf32fadd85d5938ae29d489efdd82e2cd137300 (diff)
downloadamt-jb-af66829e26cb05f182bef36ac06d58c7baa0ec1e.tar.gz
amt-jb-af66829e26cb05f182bef36ac06d58c7baa0ec1e.zip
AMTManager moved to fixture, and dectorator with parameters on tasks and init / non-static class appraoch. More assertion checks and typing. TestMTurkClient seperated from TestAMTManger
Diffstat (limited to 'tests/managers/test_hit.py')
-rw-r--r--tests/managers/test_hit.py14
1 files changed, 6 insertions, 8 deletions
diff --git a/tests/managers/test_hit.py b/tests/managers/test_hit.py
index 56a4f53..974bd18 100644
--- a/tests/managers/test_hit.py
+++ b/tests/managers/test_hit.py
@@ -11,21 +11,19 @@ class TestHitQuestionManager:
class TestHitTypeManager:
- def test_create(self, htm: HitTypeManager, hit_type_record_with_amt_id: HitType):
+ def test_create(self, htm: HitTypeManager, hit_type_record: HitType):
- _ = hit_type_record_with_amt_id
-
- assert isinstance(hit_type_record_with_amt_id.id, int)
- assert isinstance(hit_type_record_with_amt_id.amt_hit_type_id, str)
+ assert isinstance(hit_type_record.id, int)
+ assert isinstance(hit_type_record.amt_hit_type_id, str)
count1 = len(htm.filter_active())
# assert count1 == 1
- hit_type_record_with_amt_id.min_active = 0
- htm.set_min_active(hit_type=hit_type_record_with_amt_id)
+ hit_type_record.min_active = 0
+ htm.set_min_active(hit_type=hit_type_record)
count2 = len(htm.filter_active())
- assert count2 == 0
+ assert count1 - 1 == count2
class TestHitManager: