Skip to content

Commit

Permalink
test(decoder): extend fixture scope to session
Browse files Browse the repository at this point in the history
  • Loading branch information
dacorvo committed Jan 25, 2024
1 parent eeb19ef commit 70c4da9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/generation/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
}


@pytest.fixture(scope="module", params=[DECODER_MODEL_NAMES[model_arch] for model_arch in DECODER_MODEL_ARCHITECTURES])
@pytest.fixture(scope="session", params=[DECODER_MODEL_NAMES[model_arch] for model_arch in DECODER_MODEL_ARCHITECTURES])
def export_decoder_id(request):
return request.param

Expand All @@ -66,7 +66,7 @@ def export_seq2seq_model_class(request):
return request.param


@pytest.fixture(scope="module")
@pytest.fixture(scope="session")
@requires_neuronx
def neuron_decoder_path(export_decoder_id):
model = NeuronModelForCausalLM.from_pretrained(
Expand Down Expand Up @@ -161,7 +161,7 @@ def neuron_seq2seq_greedy_path_with_optional_outputs(export_seq2seq_id):
yield model_path


@pytest.fixture(scope="module")
@pytest.fixture(scope="session")
def neuron_push_decoder_id(export_decoder_id):
model_name = export_decoder_id.split("/")[-1]
repo_id = f"{USER}/{model_name}-neuronx"
Expand Down

0 comments on commit 70c4da9

Please sign in to comment.