Skip to content

Commit 26c588f

Browse files
committed
Test
1 parent 7b7ea62 commit 26c588f

File tree

5 files changed

+35
-16
lines changed

5 files changed

+35
-16
lines changed

.github/actions/test-all-eamxx/action.yml

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ inputs:
4141
description: 'Semicolon-separated list of key=value pairs for CMake to pass to test-all-eamxx'
4242
required: false
4343
default: ''
44+
kokkos_develop:
45+
description: 'Whether or not this is a test using Kokkos develop branch'
46+
required: false
47+
default: 'false'
48+
valid_values:
49+
- 'true'
50+
- 'false'
4451

4552
runs:
4653
using: "composite"
@@ -72,12 +79,16 @@ runs:
7279
- name: Print build specs
7380
run: |
7481
echo "Testing EAMxx standalone, for the following configuration:"
75-
echo " build type : ${{ inputs.build_type }}"
76-
echo " machine : ${{ inputs.machine }}"
77-
echo " generate : ${{ inputs.generate }}"
78-
echo " submit : ${{ inputs.submit }}"
79-
echo " cmake-configs: ${{ inputs.cmake-configs }}"
82+
echo " build type : ${{ inputs.build_type }}"
83+
echo " machine : ${{ inputs.machine }}"
84+
echo " generate : ${{ inputs.generate }}"
85+
echo " submit : ${{ inputs.submit }}"
86+
echo " cmake-configs : ${{ inputs.cmake-configs }}"
87+
echo " kokkos develop: ${{ inputs.kokkos_develop }}"
8088
shell: sh
89+
- name: Checkout Kokkos develop branch
90+
if: ${{inputs.kokkos_develop}}
91+
uses: ./.github/actions/update-to-kokkos-develop
8192
- name: Run test-all-eamxx
8293
working-directory: components/eamxx
8394
run: |
@@ -98,6 +109,11 @@ runs:
98109
cmd+=" -c $config"
99110
done
100111
112+
# Add additional id for CDASH submit if this is a kokkos-develop test
113+
if [ "${{ inputs.kokkos_develop }}" = "true" ]; then
114+
cmd+=" --additional-id kokkos_develop"
115+
fi
116+
101117
# Print the full command, then run it
102118
echo "test-all-eamxx call: $cmd"
103119
$cmd

.github/actions/update-to-kokkos-develop/action.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,4 @@ runs:
1919
echo "set(CMAKE_CXX_STANDARD 20 CACHE STRING \"\" FORCE)" >> $cmake_file
2020
echo "set(Kokkos_ENABLE_IMPL_VIEW_LEGACY ON CACHE BOOL \"\" FORCE)" >> $cmake_file
2121
echo "set(Kokkos_ENABLE_DEPRECATED_CODE_4 ON CACHE BOOL \"\" FORCE)" >> $cmake_file
22-
cat $cmake_file
2322
shell: sh

.github/workflows/eamxx-sa-testing.yml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,6 @@ jobs:
8989
submodules: recursive
9090
- name: Show action trigger
9191
uses: ./.github/actions/show-workflow-trigger
92-
- name: Checkout Kokkos develop branch
93-
uses: ./.github/actions/update-to-kokkos-develop
9492
- name: Run tests
9593
uses: ./.github/actions/test-all-eamxx
9694
with:
@@ -100,6 +98,7 @@ jobs:
10098
submit: ${{ env.submit }}
10199
cmake-configs: Kokkos_ENABLE_OPENMP=ON
102100
ekat: ${{ env.ekat }}
101+
kokkos_develop: ${{ env.kokkos_dev_test }}
103102
gcc-cuda:
104103
if: |
105104
${{
@@ -114,12 +113,12 @@ jobs:
114113
fail-fast: false
115114
matrix:
116115
test:
117-
#- build_type: sp
118-
# SK: OFF
116+
- build_type: sp
117+
SK: OFF
119118
- build_type: dbg
120119
SK: ON
121-
#- build_type: opt
122-
# SK: OFF
120+
- build_type: opt
121+
SK: OFF
123122
name: gcc-cuda / ${{ matrix.test.build_type }}
124123
steps:
125124
- name: Check out the repository
@@ -159,8 +158,6 @@ jobs:
159158
exit 1
160159
;;
161160
esac
162-
- name: Checkout Kokkos develop branch
163-
uses: ./.github/actions/update-to-kokkos-develop
164161
- name: Run tests
165162
uses: ./.github/actions/test-all-eamxx
166163
with:
@@ -170,3 +167,4 @@ jobs:
170167
submit: ${{ env.submit }}
171168
cmake-configs: Kokkos_ARCH_HOPPER90=${{ env.Hopper }};Kokkos_ARCH_AMPERE80=${{ env.Ampere }};Kokkos_ARCH_VOLTA70=${{ env.Volta }};CMAKE_CUDA_ARCHITECTURES=${{ env.CUDA_ARCH }};SCREAM_SMALL_KERNELS=${{ matrix.test.SK }}
172169
ekat: ${{ env.ekat }}
170+
kokkos_develop: ${{ env.kokkos_dev_test }}

components/eamxx/scripts/test-all-eamxx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,9 @@ OR
113113
choices_doc = ", ".join(["'{}' ({})".format(k, v) for k, v in get_test_name_dict().items()])
114114
parser.add_argument("-t", "--test", dest="tests", action="append", default=[],
115115
help=f"Only run specific test configurations, choices={choices_doc}")
116+
parser.add_argument("--additional-id", default="",
117+
help="Adds an aditional identifier to the test name in BUILD_NAME_MOD, "
118+
"format: BUILD_NAME_MOD=str(test)+\"_\"+additional-id.")
116119

117120
parser.add_argument("-l", "--local", action="store_true",
118121
help="Allow to not specify a machine name, and have test-all-eamxx to look"

components/eamxx/scripts/test_all_eamxx.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ def __init__(self, cxx_compiler=None, f90_compiler=None, c_compiler=None,
3232
local=False, root_dir=None, work_dir=None,
3333
quick_rerun=False,quick_rerun_failed=False,
3434
make_parallel_level=0, ctest_parallel_level=0,
35-
extra_verbose=False, limit_test_regex=None, test_level="at", test_size=None):
35+
extra_verbose=False, limit_test_regex=None, test_level="at", test_size=None,
36+
additional_id=""):
3637
###########################################################################
3738

3839
# When using scripts-tests, we can't pass "-l" to test-all-eamxx,
@@ -61,6 +62,7 @@ def __init__(self, cxx_compiler=None, f90_compiler=None, c_compiler=None,
6162
self._test_level = test_level
6263
self._test_size = test_size
6364
self._generate = generate
65+
self._additional_id = additional_id
6466

6567
if self._quick_rerun_failed:
6668
self._quick_rerun = True
@@ -474,7 +476,8 @@ def generate_ctest_config(self, cmake_config, extra_configs, test):
474476
result += f"-DBUILD_WORK_DIR={work_dir} "
475477

476478
build_name_mod = str(test)
477-
result += f"-DBUILD_NAME_MOD={build_name_mod} "
479+
testid = "_" + self._additional_id if self._additional_id != "" else ""
480+
result += f"-DBUILD_NAME_MOD={build_name_mod}{testid} "
478481

479482
if self._limit_test_regex:
480483
result += f"-DINCLUDE_REGEX={self._limit_test_regex} "

0 commit comments

Comments
 (0)