From 58ff7b1e07df7344521fdbe96bcd606515841b24 Mon Sep 17 00:00:00 2001 From: liangyongxiong Date: Thu, 23 Dec 2021 10:37:05 +0800 Subject: [PATCH] add @security_off_wrap for RDR testcases --- tests/st/data_transfer/test_tdt_data_transfer_enable_rdr.py | 3 +++ tests/st/networks/test_ascend_lenet_enable_rdr.py | 2 ++ tests/st/networks/test_cpu_lenet_enable_rdr.py | 2 ++ tests/st/networks/test_gpu_lenet_enable_rdr.py | 3 +++ 4 files changed, 10 insertions(+) diff --git a/tests/st/data_transfer/test_tdt_data_transfer_enable_rdr.py b/tests/st/data_transfer/test_tdt_data_transfer_enable_rdr.py index afc1a609749..b1bc2bffc04 100644 --- a/tests/st/data_transfer/test_tdt_data_transfer_enable_rdr.py +++ b/tests/st/data_transfer/test_tdt_data_transfer_enable_rdr.py @@ -18,6 +18,7 @@ import json import pytest import mindspore.context as context +from tests.security_utils import security_off_wrap from .test_tdt_data_transfer import test_tdt_consume_beyond_produce # create config file for RDR @@ -35,12 +36,14 @@ def test_train(device_type): context.set_context(env_config_path=config_file) test_tdt_consume_beyond_produce() +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_arm_ascend_training @pytest.mark.env_onecard def test_train_with_Ascend(): test_train("Ascend") +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_x86_gpu_training @pytest.mark.env_onecard diff --git a/tests/st/networks/test_ascend_lenet_enable_rdr.py b/tests/st/networks/test_ascend_lenet_enable_rdr.py index 370a8831f64..cb0874d132a 100644 --- a/tests/st/networks/test_ascend_lenet_enable_rdr.py +++ b/tests/st/networks/test_ascend_lenet_enable_rdr.py @@ -4,6 +4,7 @@ import json import pytest import mindspore.context as context +from tests.security_utils import security_off_wrap from .test_network_main import test_lenet # create config file for RDR @@ -21,6 +22,7 @@ def test_train(device_type): context.set_context(env_config_path=config_file) test_lenet() +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_arm_ascend_training @pytest.mark.env_onecard diff --git a/tests/st/networks/test_cpu_lenet_enable_rdr.py b/tests/st/networks/test_cpu_lenet_enable_rdr.py index f5ce60e9823..8e0f003fddc 100644 --- a/tests/st/networks/test_cpu_lenet_enable_rdr.py +++ b/tests/st/networks/test_cpu_lenet_enable_rdr.py @@ -4,6 +4,7 @@ import json import pytest import mindspore.context as context +from tests.security_utils import security_off_wrap from .test_network_main import test_lenet # create config file for RDR @@ -21,6 +22,7 @@ def test_train(device_type): context.set_context(env_config_path=config_file) test_lenet() +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_x86_cpu @pytest.mark.env_onecard diff --git a/tests/st/networks/test_gpu_lenet_enable_rdr.py b/tests/st/networks/test_gpu_lenet_enable_rdr.py index 0026f700097..fbc8e561d83 100644 --- a/tests/st/networks/test_gpu_lenet_enable_rdr.py +++ b/tests/st/networks/test_gpu_lenet_enable_rdr.py @@ -4,6 +4,7 @@ import json import pytest import mindspore.context as context +from tests.security_utils import security_off_wrap from .test_gpu_lenet import test_train_lenet, test_train_and_eval_lenet # create config file for RDR @@ -29,12 +30,14 @@ def test_train_and_eval(): # train and eval with GPU test_train_and_eval_lenet() +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_x86_gpu_training @pytest.mark.env_onecard def test_train_with_GPU(): test_train("GPU") +@security_off_wrap @pytest.mark.level0 @pytest.mark.platform_x86_gpu_training @pytest.mark.env_onecard