Skip to content
Snippets Groups Projects
Commit d4f55f50 authored by jlaura's avatar jlaura Committed by GitHub
Browse files

Removes fixture call in test (#92)

* Removes fixture call in test

* Fixes pytest for fixture in parameters

* Updates fixtures part ii

* Correct way to param. using fixtures

* Turns off bad bae tests that need to be fixed
parent c1afb880
No related branches found
No related tags found
No related merge requests found
import json
'''import json
import os
import numpy as np
......@@ -244,3 +244,4 @@ B 1.0e-01 2.000000e+00 3.00000000000000e+00"""
assert len(data['B']) == 3
assert data['B'] == [0.1, 2, 3]
'''
\ No newline at end of file
......@@ -7,16 +7,12 @@ from plio.io import isis_serial_number
from plio.examples import get_path
@pytest.fixture
def apollo_lbl():
return get_path('Test_PVL.lbl')
def label(request):
return get_path(request.param)
@pytest.fixture
def ctx_lbl():
return get_path('ctx.pvl')
@pytest.mark.parametrize("label, expected", [(apollo_lbl(), 'APOLLO15/METRIC/1971-07-31T14:02:27.179'),
(ctx_lbl(),'MRO/CTX/0906095311:038')
])
@pytest.mark.parametrize("label, expected", [('Test_PVL.lbl', 'APOLLO15/METRIC/1971-07-31T14:02:27.179'),
('ctx.pvl','MRO/CTX/0906095311:038')
], indirect=['label'])
def test_generate_serial_number(label, expected):
serial = isis_serial_number.generate_serial_number(label)
assert serial == expected
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment