diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 27431cb2..02778d35 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -25,14 +25,14 @@ scn4m_subm: - .coverage.* expire_in: 1 week -# s8: -# stage: test -# script: -# - coverage run -p $OPENRAM_HOME/tests/regress.py -t s8 -# artifacts: -# paths: -# - .coverage.* -# expire_in: 1 week +s8: + stage: test + script: + - coverage run -p $OPENRAM_HOME/tests/regress.py -t s8 + artifacts: + paths: + - .coverage.* + expire_in: 1 week coverage: stage: coverage diff --git a/compiler/tests/regress.py b/compiler/tests/regress.py index e60b010d..80754d0e 100755 --- a/compiler/tests/regress.py +++ b/compiler/tests/regress.py @@ -12,6 +12,7 @@ import unittest import sys,os sys.path.append(os.getenv("OPENRAM_HOME")) import globals +import debug (OPTS, args) = globals.parse_args() del sys.argv[1:] @@ -22,14 +23,25 @@ header(__file__, OPTS.tech_name) # get a list of all files in the tests directory files = os.listdir(sys.path[0]) +# load a file with all tests to skip in a given technology +# since tech_name is dynamically loaded, we can't use @skip directives +try: + skip_file = open("skip_tests_{}.txt".format(OPTS.tech_name), "r") + skip_tests = skip_file.read().splitlines() + for st in skip_tests: + debug.warning("Skipping: " + st) +except FileNotFoundError: + skip_tests = [] + # assume any file that ends in "test.py" in it is a regression test nametest = re.compile("test\.py$", re.IGNORECASE) -tests = list(filter(nametest.search, files)) -tests.sort() +all_tests = list(filter(nametest.search, files)) +filtered_tests = list(filter(lambda i: i not in skip_tests, all_tests)) +filtered_tests.sort() # import all of the modules filenameToModuleName = lambda f: os.path.splitext(f)[0] -moduleNames = map(filenameToModuleName, tests) +moduleNames = map(filenameToModuleName, filtered_tests) modules = map(__import__, moduleNames) suite = unittest.TestSuite() load = unittest.defaultTestLoader.loadTestsFromModule diff --git a/compiler/tests/skip_tests_s8.txt b/compiler/tests/skip_tests_s8.txt new file mode 100644 index 00000000..8e0f1746 --- /dev/null +++ b/compiler/tests/skip_tests_s8.txt @@ -0,0 +1,56 @@ +04_dummy_pbitcell_test.py +04_pbitcell_test.py +04_precharge_pbitcell_test.py +04_replica_pbitcell_test.py +04_single_level_column_mux_pbitcell_test.py +05_pbitcell_array_test.py +06_hierarchical_decoder_pbitcell_test.py +06_hierarchical_predecode2x4_pbitcell_test.py +06_hierarchical_predecode3x8_pbitcell_test.py +07_single_level_column_mux_array_pbitcell_test.py +08_wordline_driver_array_pbitcell_test.py +09_sense_amp_array_test_pbitcell.py +10_write_driver_array_pbitcell_test.py +10_write_driver_array_wmask_pbitcell_test.py +10_write_mask_and_array_pbitcell_test.py +14_replica_pbitcell_array_test.py +19_bank_select_pbitcell_test.py +05_bitcell_1rw_1r_array_test.py +05_bitcell_array_test.py +05_dummy_array_test.py +05_pbitcell_array_test.py +06_hierarchical_decoder_pbitcell_test.py +06_hierarchical_decoder_test.py +06_hierarchical_predecode2x4_pbitcell_test.py +06_hierarchical_predecode2x4_test.py +06_hierarchical_predecode3x8_pbitcell_test.py +06_hierarchical_predecode3x8_test.py +06_hierarchical_predecode4x16_test.py +04_dummy_pbitcell_test.py +04_pbitcell_test.py +04_precharge_pbitcell_test.py +04_replica_pbitcell_test.py +04_single_level_column_mux_pbitcell_test.py +05_bitcell_1rw_1r_array_test.py +05_bitcell_array_test.py +05_dummy_array_test.py +05_pbitcell_array_test.py +05_pbitcell_array_test.py +06_hierarchical_decoder_pbitcell_test.py +06_hierarchical_decoder_pbitcell_test.py +06_hierarchical_decoder_test.py +06_hierarchical_predecode2x4_pbitcell_test.py +06_hierarchical_predecode2x4_pbitcell_test.py +06_hierarchical_predecode2x4_test.py +06_hierarchical_predecode3x8_pbitcell_test.py +06_hierarchical_predecode3x8_pbitcell_test.py +06_hierarchical_predecode3x8_test.py +06_hierarchical_predecode4x16_test.py +07_single_level_column_mux_array_pbitcell_test.py +08_wordline_driver_array_pbitcell_test.py +09_sense_amp_array_test_pbitcell.py +10_write_driver_array_pbitcell_test.py +10_write_driver_array_wmask_pbitcell_test.py +10_write_mask_and_array_pbitcell_test.py +14_replica_pbitcell_array_test.py +19_bank_select_pbitcell_test.py