Bobby R. Bruce has submitted this change. ( https://gem5-review.googlesource.com/c/public/gem5/+/49557 )


21 is the latest approved patch-set.
No files were changed between the latest approved patch-set and the submitted one.
Change subject: tests: Update test_exit.py to run with simple_binary_run.py
......................................................................

tests: Update test_exit.py to run with simple_binary_run.py

In addition, Python black has been run on simple_binary_run.py

Change-Id: I6e7580f7bbdf249a081302dd46a14df95d7d53bb
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/49557
Tested-by: kokoro <[email protected]>
Reviewed-by: Jason Lowe-Power <[email protected]>
Maintainer: Jason Lowe-Power <[email protected]>
---
M tests/gem5/m5_util/test_exit.py
1 file changed, 24 insertions(+), 13 deletions(-)

Approvals:
  Jason Lowe-Power: Looks good to me, approved; Looks good to me, approved
  kokoro: Regressions pass




diff --git a/tests/gem5/m5_util/test_exit.py b/tests/gem5/m5_util/test_exit.py
index 1bc6e6f..413b6ea 100644
--- a/tests/gem5/m5_util/test_exit.py
+++ b/tests/gem5/m5_util/test_exit.py
@@ -36,28 +36,39 @@
 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

-'''
+"""
 Test file for the util m5 exit assembly instruction.
-'''
+"""
 import re
-import os
 from testlib import *

 m5_exit_regex = re.compile(
-r'Exiting @ tick \d* because m5_exit instruction encountered'
+    r"Exiting @ tick \d* because m5_exit instruction encountered"
 )

-path = joinpath(config.bin_path, 'test-progs', 'hello', 'bin', 'x86', 'linux')
-filename = 'm5_exit'
-url = (config.resource_url + '/test-progs/m5-exit/bin/x86/linux/m5_exit')
-test_program = DownloadedProgram(url, path, filename)
+if config.bin_path:
+    resource_path = config.bin_path
+else:
+    resource_path = joinpath(absdirpath(__file__), "..", "resources")

 a = verifier.MatchRegex(m5_exit_regex)
 gem5_verify_config(
-    name='m5_exit_test',
+    name="m5_exit_test",
     verifiers=[a],
-    fixtures=(test_program,),
-    config=os.path.join(config.base_dir, 'configs', 'example','se.py'),
-    config_args=['--cmd', joinpath(test_program.path, filename)],
-    valid_isas=(constants.gcn3_x86_tag,)
+    fixtures=(),
+    config=joinpath(
+        config.base_dir,
+        "configs",
+        "example",
+        "components-library",
+        "simple_binary_run.py",
+    ),
+    config_args=[
+        "x86-m5-exit",
+        "atomic",
+        "--override-download",
+        "--resource-directory",
+        resource_path,
+    ],
+    valid_isas=(constants.gcn3_x86_tag,),
 )

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/49557
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I6e7580f7bbdf249a081302dd46a14df95d7d53bb
Gerrit-Change-Number: 49557
Gerrit-PatchSet: 26
Gerrit-Owner: Bobby R. Bruce <[email protected]>
Gerrit-Reviewer: Bobby R. Bruce <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: kokoro <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to