@@ -119,17 +119,44 @@ jobs:
119
119
-r ${{ github.workspace }}
120
120
121
121
# checkout NUOPC app prototypes
122
- - name : Checkout NUOPC app prototypes
122
+ - name : Checkout NUOPC App Prototypes
123
123
uses : actions/checkout@v3
124
124
with :
125
125
repository : esmf-org/nuopc-app-prototypes
126
126
path : ${{ github.workspace }}/nuopc-app-prototypes
127
127
ref : ${{ needs.set-matrix.outputs.nuopc_app_version }}
128
128
129
129
# test installation using NUOPC app prototypes
130
- - name : Run NUOPC app prototypes
130
+ - name : Run NUOPC App Prototypes
131
131
run : |
132
132
${{ github.workspace }}/.github/workflows/scripts/run_nuopc_app_proto.sh \
133
133
-c ${{ matrix.compiler }} \
134
134
-r ${{ github.workspace }}/nuopc-app-prototypes \
135
135
-s ~/.spack-ci
136
+
137
+ # compress run directory of NUOPC app prototypes
138
+ - name : Prepare NUOPC App Prototypes Artifacts Directory
139
+ run : |
140
+ cd ${{ github.workspace }}/nuopc-app-prototypes
141
+ mkdir Artifacts
142
+ mv NUOPC-PROTO-RESULTS Artifacts/
143
+
144
+ # push test results to artifacts
145
+ - name : Upload Artifacts
146
+ uses : actions/upload-artifact@v3
147
+ with :
148
+ name : Artifacts for ${{ matrix.compiler }} ${{ matrix.esmf }}
149
+ path : ${{ github.workspace }}/nuopc-app-prototypes/Artifacts
150
+ retention-days : 5
151
+
152
+ # force to fail if there is any failed nuopc app prototypes
153
+ - name : Check Result of NUOPC App Prototypes
154
+ run : |
155
+ if [[ "${{ env.NUOPC_APP_PROTO_PASS }}" == "false" ]]; then
156
+ echo "Some of NUOPC app prototypes are failed! Exiting ..."
157
+ exit 1
158
+ else
159
+ echo "All tests are passed."
160
+ exit 0
161
+ fi
162
+ shell : bash
0 commit comments