/* * 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 "../ActsDeqpgles20001TestSuite.h" using namespace std; using namespace testing::ext; using namespace OHOS; static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000195, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000195 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocesso" "r.comments.multiline_comment_define_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000195 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000195 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000196, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000196 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocessor" ".comments.multiline_comment_define_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000196 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000196 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000197, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000197 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.prepro" "cessor.comments.nested_comment_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000197 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000197 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000198, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000198 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproc" "essor.comments.nested_comment_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000198 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000198 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000199, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000199 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproc" "essor.comments.comment_trick_1_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000199 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000199 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000200, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000200 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproce" "ssor.comments.comment_trick_1_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000200 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000200 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000201, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000201 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproc" "essor.comments.comment_trick_2_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000201 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000201 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000202, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000202 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproce" "ssor.comments.comment_trick_2_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000202 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000202 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000203, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000203 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproc" "essor.comments.invalid_comment_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000203 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000203 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000204, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000204 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preproce" "ssor.comments.invalid_comment_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000204 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000204 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000205, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000205 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocess" "or.comments.unterminated_comment_1_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000205 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000205 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000206, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000206 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocesso" "r.comments.unterminated_comment_1_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000206 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000206 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000207, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000207 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocess" "or.comments.unterminated_comment_2_vertex", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000207 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000207 end"; } static HWTEST_F(ActsDeqpgles20001TestSuite, TestCase_000208, Function | MediumTest | Level2) { GTEST_LOG_(INFO) << "TestCase_000208 start"; int argc = 3; const char *argv[3] = { ".", "--deqp-case=" "dEQP-GLES2.functional.shaders.preprocesso" "r.comments.unterminated_comment_2_fragment", "--deqp-archive-dir=/data/local/tmp/" }; FuncRunResult result = RunTestKHRGLES(argc, argv); ActsDeqpgles20001TestSuite::runResult.numPassed += result.numPassed; ActsDeqpgles20001TestSuite::runResult.numFailed += result.numFailed; ActsDeqpgles20001TestSuite::runResult.numNotSupported += result.numNotSupported; ActsDeqpgles20001TestSuite::runResult.numWarnings += result.numWarnings; ActsDeqpgles20001TestSuite::runResult.numWaived += result.numWaived; if (result.numNotSupported == 1) { GTEST_LOG_(INFO) << "TestCase_000208 notsupport!"; } else if (result.isComplete) { EXPECT_TRUE(result.isComplete); EXPECT_TRUE(result.numPassed == 1); }; GTEST_LOG_(INFO) << "TestCase_000208 end"; }