On 27 Nov 2023, at 19:04, Ilya Maximets wrote:

> On 11/27/23 13:39, Eelco Chaudron wrote:
>> This patch also adds the 'CHECK_GITHUB_ACTION' macro to skip
>> tests that won't execute successfully through GitHub actions.
>> We could not use the -k !keyword option, as it can not be
>> combined with a range of tests.
>>
>> Signed-off-by: Eelco Chaudron <echau...@redhat.com>
>> ---
>>  .ci/linux-build.sh                   |    2 +-
>>  .github/workflows/build-and-test.yml |    7 +++++++
>>  tests/system-common-macros.at        |    4 ++++
>>  tests/system-offloads-traffic.at     |    2 ++
>>  4 files changed, 14 insertions(+), 1 deletion(-)
>>
>> diff --git a/.ci/linux-build.sh b/.ci/linux-build.sh
>> index 4f2e36610..85788748f 100755
>> --- a/.ci/linux-build.sh
>> +++ b/.ci/linux-build.sh
>> @@ -139,7 +139,7 @@ else
>>              export DPDK_EAL_OPTIONS="--lcores 0@1,1@1,2@1"
>>          fi
>>          $run_as_root make $testsuite TESTSUITEFLAGS="$JOBS $TEST_RANGE" \
>> -                                     RECHECK=yes
>> +                                     RECHECK=yes 
>> GITHUB_ACTIONS=$GITHUB_ACTIONS
>>      done
>>  fi
>>
>> diff --git a/.github/workflows/build-and-test.yml 
>> b/.github/workflows/build-and-test.yml
>> index 0b881ca91..586b0cdd9 100644
>> --- a/.github/workflows/build-and-test.yml
>> +++ b/.github/workflows/build-and-test.yml
>> @@ -176,6 +176,13 @@ jobs:
>>              testsuite:    check-kernel
>>              test_range:   "100-"
>>
>> +          - compiler:     gcc
>> +            testsuite:    check-offloads
>> +            test_range:   "-100"
>> +          - compiler:     gcc
>> +            testsuite:    check-offloads
>> +            test_range:   "100-"
>> +
>>      steps:
>>      - name: checkout
>>        uses: actions/checkout@v3
>> diff --git a/tests/system-common-macros.at b/tests/system-common-macros.at
>> index 0113aae8b..0620be0c7 100644
>> --- a/tests/system-common-macros.at
>> +++ b/tests/system-common-macros.at
>> @@ -365,3 +365,7 @@ m4_define([OVS_CHECK_IPROUTE_ENCAP],
>>  # OVS_CHECK_CT_CLEAR()
>>  m4_define([OVS_CHECK_CT_CLEAR],
>>      [AT_SKIP_IF([! grep -q "Datapath supports ct_clear action" 
>> ovs-vswitchd.log])])
>> +
>> +# OVS_CHECK_GITHUB_ACTION
>> +m4_define([OVS_CHECK_GITHUB_ACTION],
>> +    [AT_SKIP_IF([test "$GITHUB_ACTIONS" = "true"])])
>
> Can we use some pre-defined GHA env variable instead?
> Or are they not available?

This is a pre-defined GH env. See above we re-export it as we run as root.

>> diff --git a/tests/system-offloads-traffic.at 
>> b/tests/system-offloads-traffic.at
>> index 0bedee753..6bd49a3ee 100644
>> --- a/tests/system-offloads-traffic.at
>> +++ b/tests/system-offloads-traffic.at
>> @@ -192,6 +192,7 @@ AT_CLEANUP
>>  AT_SETUP([offloads - check interface meter offloading -  offloads disabled])
>>  AT_KEYWORDS([dp-meter])
>>  AT_SKIP_IF([test $HAVE_NC = "no"])
>> +OVS_CHECK_GITHUB_ACTION()
>>  OVS_TRAFFIC_VSWITCHD_START()
>>
>>  AT_CHECK([ovs-ofctl -O OpenFlow13 add-meter br0 'meter=1 pktps 
>> bands=type=drop rate=1'])
>> @@ -240,6 +241,7 @@ AT_CLEANUP
>>
>>  AT_SETUP([offloads - check interface meter offloading -  offloads enabled])
>>  AT_KEYWORDS([offload-meter])
>> +OVS_CHECK_GITHUB_ACTION()
>>  CHECK_TC_INGRESS_PPS()
>>  AT_SKIP_IF([test $HAVE_NC = "no"])
>>  OVS_TRAFFIC_VSWITCHD_START([], [], [-- set Open_vSwitch . 
>> other_config:hw-offload=true])
>>
>> _______________________________________________
>> dev mailing list
>> d...@openvswitch.org
>> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>>

_______________________________________________
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to