Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
thibaultcha committed Nov 16, 2023
1 parent 79da0c8 commit e9015ff
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 2 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,25 @@ jobs:
wasmer: 3.1.1
debug: debug
hup: no_hup
path: t/04-openresty
# Wasmtime hfuncs
- runtime: wasmtime
wasmtime: 14.0.3
os: ubuntu-22.04
cc: gcc-12
ngx: 1.25.3
hup: no_hup
debug: debug
path: t/03-proxy_wasm/hfuncs
# Wasmer hfuncs
- runtime: wasmer
wasmer: 3.1.1
os: ubuntu-22.04
cc: gcc-12
ngx: 1.25.3
hup: no_hup
debug: debug
path: t/03-proxy_wasm/hfuncs
uses: ./.github/workflows/job-valgrind-tests.yml
with:
os: ${{ matrix.os }}
Expand Down
9 changes: 8 additions & 1 deletion .github/workflows/job-valgrind-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ on:
hup:
required: true
type: string
path:
required: false
type: string

defaults:
run:
Expand All @@ -46,6 +49,7 @@ env:
NGX_BUILD_CC_OPT: '-O2'
NGX_BUILD_NOPOOL: 1
TEST_NGINX_USE_VALGRIND: 1
TEST_NGINX_USE_VALGRIND_ALL: ${{ inputs.path == '' && 0 || 1 }}
TEST_NGINX_USE_HUP: ${{ inputs.hup == 'hup' && 1 || 0 }}
TEST_NGINX_RANDOMIZE: 1
TEST_NGINX_NO_CLEAN: 1
Expand Down Expand Up @@ -101,7 +105,10 @@ jobs:
ghcr_password: ${{ secrets.TOKEN_GITHUB }}
- run: make setup
- run: make
- run: make test 2>&1 | tee valgrind.out
#- run: make test 2>&1 | tee valgrind.out
- run: |
IN_PATH="${{ github.event.inputs.path }}"
./util/test.sh ${IN_PATH:-t/} 2>&1 | tee valgrind.out
- run: |
awk -f ./util/parse-valgrind.awk valgrind.out > valgrind.log
if [[ -s valgrind.log ]]; then
Expand Down
2 changes: 1 addition & 1 deletion t/TestWasm.pm
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ add_block_preprocessor(sub {
&& $ENV{TEST_NGINX_USE_VALGRIND}
&& $block->skip_valgrind =~ m/\s*(\d+)/)
{
$block->set_value("skip_eval", sprintf '%d: $ENV{TEST_NGINX_USE_VALGRIND} && !$ENV{TEST_NGINX_USE_VALGRIND_ALL}', $1);
$block->set_value("skip_eval", sprintf '%d: $ENV{TEST_NGINX_USE_VALGRIND}', $1);
}

# --- timeout_expected: 1
Expand Down

0 comments on commit e9015ff

Please sign in to comment.