11import dataclasses
2- import sys
32from unittest .mock import AsyncMock , patch
43
54import pytest
3332from starknet_py .net .full_node_client import _to_rpc_felt
3433from starknet_py .net .models import StarknetChainId
3534from starknet_py .tests .e2e .fixtures .constants import MAX_RESOURCE_BOUNDS
36- from starknet_py .tests .e2e .fixtures .misc import load_contract
35+ from starknet_py .tests .e2e .fixtures .misc import _contract_dir , load_contract
3736
3837
3938def _parse_event_name (event : str ) -> str :
@@ -147,7 +146,7 @@ async def test_get_storage_at_incorrect_address_full_node_client(client):
147146
148147
149148@pytest .mark .skipif (
150- "--contract_dir= v1" in sys . argv ,
149+ _contract_dir == " v1" ,
151150 reason = "Contract exists only in v2 directory" ,
152151)
153152@pytest .mark .run_on_devnet
@@ -176,7 +175,7 @@ async def test_get_events_without_following_continuation_token(
176175
177176
178177@pytest .mark .skipif (
179- "--contract_dir= v1" in sys . argv ,
178+ _contract_dir == " v1" ,
180179 reason = "Contract exists only in v2 directory" ,
181180)
182181@pytest .mark .run_on_devnet
@@ -205,7 +204,7 @@ async def test_get_events_follow_continuation_token(
205204
206205
207206@pytest .mark .skipif (
208- "--contract_dir= v1" in sys . argv ,
207+ _contract_dir == " v1" ,
209208 reason = "Contract exists only in v2 directory" ,
210209)
211210@pytest .mark .run_on_devnet
@@ -232,7 +231,7 @@ async def test_get_events_nonexistent_event_name(
232231
233232
234233@pytest .mark .skipif (
235- "--contract_dir= v1" in sys . argv ,
234+ _contract_dir == " v1" ,
236235 reason = "Contract exists only in v2 directory" ,
237236)
238237@pytest .mark .run_on_devnet
@@ -285,7 +284,7 @@ async def test_get_events_with_two_events(
285284
286285
287286@pytest .mark .skipif (
288- "--contract_dir= v1" in sys . argv ,
287+ _contract_dir == " v1" ,
289288 reason = "Contract exists only in v2 directory" ,
290289)
291290@pytest .mark .run_on_devnet
@@ -316,7 +315,7 @@ async def test_get_events_start_from_continuation_token(
316315
317316
318317@pytest .mark .skipif (
319- "--contract_dir= v1" in sys . argv ,
318+ _contract_dir == " v1" ,
320319 reason = "Contract exists only in v2 directory" ,
321320)
322321@pytest .mark .run_on_devnet
@@ -339,7 +338,7 @@ async def test_get_events_no_params(
339338
340339
341340@pytest .mark .skipif (
342- "--contract_dir= v1" in sys . argv ,
341+ _contract_dir == " v1" ,
343342 reason = "Contract exists only in v2 directory" ,
344343)
345344@pytest .mark .run_on_devnet
@@ -620,7 +619,7 @@ async def test_trace_block_transactions_return_initial_reads(
620619
621620
622621@pytest .mark .skipif (
623- "--contract_dir= v1" in sys . argv ,
622+ _contract_dir == " v1" ,
624623 reason = "Contract exists only in v2 directory" ,
625624)
626625@pytest .mark .run_on_devnet
0 commit comments