diff --git a/graphic/vkgl/src/deqpgles2/functional/Deqpgles2info_query_array_in_structTestCase.cpp b/graphic/vkgl/src/deqpgles2/functional/Deqpgles2info_query_array_in_structTestCase.cpp new file mode 100644 index 0000000000000000000000000000000000000000..d1206e062dbc70b339896c5c6676f852ff7435c9 --- /dev/null +++ b/graphic/vkgl/src/deqpgles2/functional/Deqpgles2info_query_array_in_structTestCase.cpp @@ -0,0 +1,427 @@ +/* + * Copyright (c) 2022 Shenzhen Kaihong Digital Industry Development Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include "../Deqpgles2BaseFunc.h" +#include "../ActsDeqpgles20015TestSuite.h" + +using namespace std; +using namespace testing::ext; +using namespace OHOS; + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014097, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014097 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_" + "query.array_in_struct.float_vec4_vertex", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014097 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014097 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014098, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014098 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_q" + "uery.array_in_struct.float_vec4_fragment", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014098 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014098 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014099, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014099 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info" + "_query.array_in_struct.float_vec4_both", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014099 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014099 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014100, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014100 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info" + "_query.array_in_struct.mat4_mat2_vertex", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014100 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014100 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014101, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014101 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_" + "query.array_in_struct.mat4_mat2_fragment", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014101 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014101 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014102, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014102 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.inf" + "o_query.array_in_struct.mat4_mat2_both", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014102 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014102 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014103, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014103 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info" + "_query.array_in_struct.int_ivec4_vertex", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014103 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014103 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014104, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014104 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_" + "query.array_in_struct.int_ivec4_fragment", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014104 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014104 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014105, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014105 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.inf" + "o_query.array_in_struct.int_ivec4_both", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014105 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014105 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014106, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014106 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_" + "query.array_in_struct.bool_bvec4_vertex", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014106 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014106 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014107, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014107 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_q" + "uery.array_in_struct.bool_bvec4_fragment", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014107 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014107 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014108, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014108 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info" + "_query.array_in_struct.bool_bvec4_both", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014108 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014108 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014109, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014109 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_query" + ".array_in_struct.sampler2D_samplerCube_vertex", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014109 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014109 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014110, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014110 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_query." + "array_in_struct.sampler2D_samplerCube_fragment", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014110 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014110 end"; +} + +static HWTEST_F(ActsDeqpgles20015TestSuite, TestCase_014111, Function | MediumTest | Level2) +{ + GTEST_LOG_(INFO) << "TestCase_014111 start"; + int argc = 3; + const char *argv[3] = { + ".", + "--deqp-case=" + "dEQP-GLES2.functional.uniform_api.info_quer" + "y.array_in_struct.sampler2D_samplerCube_both", + "--deqp-archive-dir=/data/local/tmp/" + }; + + FuncRunResult result = RunTestKHRGLES(argc, argv); + ActsDeqpgles20015TestSuite::runResult.numPassed += result.numPassed; + ActsDeqpgles20015TestSuite::runResult.numFailed += result.numFailed; + ActsDeqpgles20015TestSuite::runResult.numNotSupported += result.numNotSupported; + ActsDeqpgles20015TestSuite::runResult.numWarnings += result.numWarnings; + ActsDeqpgles20015TestSuite::runResult.numWaived += result.numWaived; + if (result.numNotSupported == 1) { + GTEST_LOG_(INFO) << "TestCase_014111 notsupport!"; + } else if (result.isComplete) { + EXPECT_TRUE(result.isComplete); + EXPECT_TRUE(result.numPassed == 1); + }; + GTEST_LOG_(INFO) << "TestCase_014111 end"; +}