77
88import responses # type: ignore
99
10- from build .lib .smart_tests .utils .session import write_session
1110from smart_tests .utils .http_client import get_base_url
1211from tests .cli_test_case import CliTestCase
1312
@@ -161,7 +160,7 @@ def test_attachment_with_include_filter(self):
161160 self .assertEqual (expect , result .output )
162161
163162 @responses .activate
164- @mock .patch .dict (os .environ , {"LAUNCHABLE_TOKEN " : CliTestCase .launchable_token })
163+ @mock .patch .dict (os .environ , {"SMART_TESTS_TOKEN " : CliTestCase .smart_tests_token })
165164 def test_attachment_with_identical_file_names (self ):
166165 with tempfile .TemporaryDirectory () as temp_dir :
167166 # Create temporary files
@@ -216,13 +215,10 @@ def test_attachment_with_identical_file_names(self):
216215 self .assertEqual (expect , result .output )
217216
218217 @responses .activate
219- @mock .patch .dict (os .environ , {"LAUNCHABLE_TOKEN " : CliTestCase .launchable_token })
218+ @mock .patch .dict (os .environ , {"SMART_TESTS_TOKEN " : CliTestCase .smart_tests_token })
220219 def test_attachment_with_whitespace_in_filename (self ):
221220 TEST_CONTENT = b"Test log content"
222221
223- # emulate launchable record build & session
224- write_session (self .build_name , self .session_id )
225-
226222 # Create a file with whitespace in the name
227223 with tempfile .TemporaryDirectory () as temp_dir :
228224 file_path = os .path .join (temp_dir , "app log file.txt" )
@@ -245,7 +241,7 @@ def test_attachment_with_whitespace_in_filename(self):
245241 self .assertIn ("✓ Recorded successfully" , result .output )
246242
247243 @responses .activate
248- @mock .patch .dict (os .environ , {"LAUNCHABLE_TOKEN " : CliTestCase .launchable_token })
244+ @mock .patch .dict (os .environ , {"SMART_TESTS_TOKEN " : CliTestCase .smart_tests_token })
249245 def test_attachment_duplicate_file_paths (self ):
250246 with tempfile .TemporaryDirectory () as temp_dir :
251247 # Create temporary files
0 commit comments