Skip to content

Commit 183ba64

Browse files
author
Matt Sokoloff
committed
update tests
1 parent 137ed0f commit 183ba64

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

tests/integration/conftest.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ def submit(project_id, data_row_id):
311311
})
312312
features = feature_result['project']['featuresForDataRow']
313313
feature_ids = [feature['id'] for feature in features]
314-
client.execute(
314+
res = client.execute(
315315
"""mutation createLabelPyApi ($project_id : ID!,$datarow_id: ID!,$feature_ids: [ID!]!,$time_seconds : Float!) {
316316
createLabelFromFeatures(data: {dataRow: { id: $datarow_id },project: { id: $project_id },
317317
featureIds: $feature_ids,secondsSpent: $time_seconds}) {id}}""",
@@ -321,6 +321,7 @@ def submit(project_id, data_row_id):
321321
"feature_ids": feature_ids,
322322
"time_seconds": 10
323323
})
324+
return res['createLabelFromFeatures']['id']
324325

325326
return submit
326327

@@ -357,9 +358,8 @@ def configured_project_with_label(client, rand_gen, annotation_submit_fn,
357358
upload_task = MALPredictionImport.create_from_objects(
358359
client, project.uid, f'mal-import-{uuid.uuid4()}', predictions)
359360
upload_task.wait_until_done()
360-
time.sleep(2)
361-
annotation_submit_fn(project.uid, data_row.uid)
362-
time.sleep(2)
363-
yield project
361+
labels = annotation_submit_fn(project.uid, data_row.uid)
362+
time.sleep(3)
363+
yield [project, labels]
364364
dataset.delete()
365365
project.delete()

0 commit comments

Comments
 (0)