1//===-- Tests for Test Filter functionality -------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#include "test/UnitTest/LibcTest.h"
10
11TEST(LlvmLibcTestFilterTest, CorrectFilter) {}
12
13TEST(LlvmLibcTestFilterTest, CorrectFilter2) {}
14
15TEST(LlvmLibcTestFilterTest, IncorrectFilter) {}
16
17TEST(LlvmLibcTestFilterTest, NoFilter) {}
18
19TEST(LlvmLibcTestFilterTest, CheckCorrectFilter) {
20 ASSERT_EQ(LIBC_NAMESPACE::testing::Test::runTests(
21 "LlvmLibcTestFilterTest.NoFilter"),
22 0);
23 ASSERT_EQ(LIBC_NAMESPACE::testing::Test::runTests(
24 "LlvmLibcTestFilterTest.IncorrFilter"),
25 1);
26 ASSERT_EQ(LIBC_NAMESPACE::testing::Test::runTests(
27 "LlvmLibcTestFilterTest.CorrectFilter"),
28 0);
29 ASSERT_EQ(LIBC_NAMESPACE::testing::Test::runTests(
30 "LlvmLibcTestFilterTest.CorrectFilter2"),
31 0);
32}
33
34int main() {
35 LIBC_NAMESPACE::testing::Test::runTests(
36 "LlvmLibcTestFilterTest.CheckCorrectFilter");
37 return 0;
38}
39

source code of libc/test/utils/UnitTest/testfilter_test.cpp