11import os
22import shutil
3+ import re
34
45from integration_tests .config import PARENT_OUTPUT_FOLDER
56from integration_tests .shared import download_project_repository , run_docker
67from multiversx_sdk_rust_contract_builder .packaged_source_code import \
78 PackagedSourceCode
89
9- DEFAULT_PROJECT_ARCHIVE_URL = "https://github.com/multiversx/mx-sovereign-sc/archive/87f1e57978190cb7fff805fea6ed194aa8411567 .zip"
10- DEFAULT_PROJECT_ARCHIVE_PAYLOAD = "mx-sovereign-sc-87f1e57978190cb7fff805fea6ed194aa8411567 "
11- DEFAULT_CONTRACT_NAME = "esdt-safe"
10+ DEFAULT_PROJECT_ARCHIVE_URL = "https://github.com/multiversx/mx-sovereign-sc/archive/e9a4f1fc8d963d48cbce0fb0cf673621cc0832ac .zip"
11+ DEFAULT_PROJECT_ARCHIVE_PAYLOAD = "mx-sovereign-sc-e9a4f1fc8d963d48cbce0fb0cf673621cc0832ac "
12+ DEFAULT_CONTRACT_NAME = "sov- esdt-safe"
1213
1314
1415def test_with_symlinks ():
@@ -62,7 +63,9 @@ def test_has_correct_packaged_source():
6263
6364 for entry in packaged_source_code .entries :
6465 assert not str (entry .path ).startswith ("target" ), f"Unexpected file: { entry .path } "
65- assert entry .is_test_file == ("test" in str (entry .path )), f"Unexpected is_test_file marker for: { entry .path } "
66+
67+ is_test_file = ("tests" in str (entry .path )) or ("test_" in str (entry .path )) or ("_test" in str (entry .path ))
68+ assert entry .is_test_file == is_test_file , f"Unexpected is_test_file marker for: { entry .path } "
6669
6770
6871def test_fail_if_contract_cargo_lock_is_missing ():
@@ -74,7 +77,7 @@ def test_fail_if_contract_cargo_lock_is_missing():
7477 output_folder .mkdir (parents = True , exist_ok = True )
7578
7679 # Remove a (required) Cargo.lock file
77- (workspace / DEFAULT_CONTRACT_NAME / "wasm" / "Cargo.lock" ).unlink ()
80+ (workspace / DEFAULT_CONTRACT_NAME / f "wasm- { DEFAULT_CONTRACT_NAME } " / "Cargo.lock" ).unlink ()
7881
7982 (code , _ , stderr ) = run_docker (
8083 project_path = workspace ,
0 commit comments