@@ -332,11 +332,11 @@ def test_raises_error_for_duplicate():
332
332
def test_dataset_export_autotag_tagged_items (CLIENT ):
333
333
# This test can only run for the test user who has an indexed dataset.
334
334
# TODO: if/when we can create autotags via api, create one instead.
335
- if NUCLEUS_PYTEST_USER_ID in CLIENT . api_key :
335
+ if NUCLEUS_PYTEST_USER_ID in os . environ [ "NUCLEUS_PYTEST_USER_ID" ] :
336
336
dataset = CLIENT .get_dataset (DATASET_WITH_AUTOTAG )
337
337
338
338
with pytest .raises (NucleusAPIError ) as api_error :
339
- dataset .autotag_scores (autotag_name = "NONSENSE_GARBAGE" )
339
+ dataset .autotag_items (autotag_name = "NONSENSE_GARBAGE" )
340
340
assert (
341
341
f"The autotag NONSENSE_GARBAGE was not found in dataset { DATASET_WITH_AUTOTAG } "
342
342
in str (api_error .value )
@@ -362,19 +362,19 @@ def test_dataset_export_autotag_tagged_items(CLIENT):
362
362
def test_dataset_export_autotag_training_items (CLIENT ):
363
363
# This test can only run for the test user who has an indexed dataset.
364
364
# TODO: if/when we can create autotags via api, create one instead.
365
- if NUCLEUS_PYTEST_USER_ID in CLIENT . api_key :
365
+ if NUCLEUS_PYTEST_USER_ID in os . environ [ "NUCLEUS_PYTEST_USER_ID" ] :
366
366
dataset = CLIENT .get_dataset (DATASET_WITH_AUTOTAG )
367
367
368
368
with pytest .raises (NucleusAPIError ) as api_error :
369
- dataset .autotag_scores (autotag_name = "NONSENSE_GARBAGE" )
369
+ dataset .autotag_training_items (autotag_name = "NONSENSE_GARBAGE" )
370
370
assert (
371
371
f"The autotag NONSENSE_GARBAGE was not found in dataset { DATASET_WITH_AUTOTAG } "
372
372
in str (api_error .value )
373
373
)
374
374
375
375
items = dataset .autotag_training_items (autotag_name = "PytestTestTag" )
376
376
377
- assert "autotagItems " in items
377
+ assert "autotagPositiveTrainingItems " in items
378
378
assert "autotag" in items
379
379
380
380
autotagTrainingItems = items ["autotagPositiveTrainingItems" ]
0 commit comments