On Fri, Oct 6, 2017 at 3:27 PM, Aaron Ballman via cfe-commits <
cfe-commits@lists.llvm.org> wrote:

> Author: aaronballman
> Date: Fri Oct  6 06:27:59 2017
> New Revision: 315060
>
> URL: http://llvm.org/viewvc/llvm-project?rev=315060&view=rev
> Log:
> Renaming a test to start with the name of the check based on post-commit
> review feedback; NFC.
>
> Added:
>     clang-tools-extra/trunk/test/clang-tidy/google-readability-
> namespace-comments-cxx17
>

Sorry for not being clear. I didn't mean the `.cpp` extension should be
removed. This effectively disables the test, since lit only runs tests in
files with certain extensions (under clang-tools-extra/test these are '.c',
'.cpp', '.hpp', '.m', '.mm', '.cu', '.ll', '.cl', '.s', '.modularize',
'.module-map-checker', '.test').

I've just renamed the file to *.cpp and the test fails for me:

[0/1] Running the Clang extra tools' regression tests
FAIL: Clang Tools ::
clang-tidy/google-readability-namespace-comments-cxx17.cpp (102 of 674)

******************** TEST 'Clang Tools ::
clang-tidy/google-readability-namespace-comments-cxx17.cpp' FAILED
********************

Script:
--
/usr/bin/python2.7
/src/tools/clang/tools/extra/test/../test/clang-tidy/check_clang_tidy.py
/src/tools/clang/tools/extra/test/clang-tidy/google-readability-namespace-comments-cxx17.cpp
google-readability-namespace-comments
/build/tools/clang/tools/extra/test/clang-tidy/Output/google-readability-namespace-comments-cxx17.cpp.tmp
-- -- -std=c++17
--
Exit Code: 1

Command Output (stdout):
--
Running ['clang-tidy',
'/build/tools/clang/tools/extra/test/clang-tidy/Output/google-readability-namespace-comments-cxx17.cpp.tmp.cpp',
'-fix', '--checks=-*,google-readability-namespace-comments', '--',
'-std=c++17', '-nostdinc++']...
------------------------ clang-tidy output -----------------------


------------------------------------------------------------------

------------------------------ Fixes -----------------------------


------------------------------------------------------------------

FileCheck failed:
/src/tools/clang/tools/extra/test/clang-tidy/google-readability-namespace-comments-cxx17.cpp:13:17:
error: expected string not found in input

// CHECK-FIXES: }  // namespace n3
                ^
/build/tools/clang/tools/extra/test/clang-tidy/Output/google-readability-namespace-comments-cxx17.cpp.tmp.cpp:1:1:
note: scanning from here

// RUN: %check_clang_tidy %s google-readability-namespace-comments %t -- --
-std=c++17
^
/build/tools/clang/tools/extra/test/clang-tidy/Output/google-readability-namespace-comments-cxx17.cpp.tmp.cpp:5:7:
note: possible intended match here

  // So that namespace is not empty.
      ^


--
Command Output (stderr):
--
Traceback (most recent call last):
  File
"/src/tools/clang/tools/extra/test/../test/clang-tidy/check_clang_tidy.py",
line 140, in <module>
    main()
  File
"/src/tools/clang/tools/extra/test/../test/clang-tidy/check_clang_tidy.py",
line 121, in main
    stderr=subprocess.STDOUT)
  File "/usr/lib/python2.7/subprocess.py", line 573, in check_output

    raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '['FileCheck',
'-input-file=/build/tools/clang/tools/extra/test/clang-tidy/Output/google-readability-namespace-comments-cxx17.cpp.tmp.cpp',
'/src/tools/clang/tools/extra/test/clang-tidy/google-readability-namespace-comments-cxx17.cpp',
'-check-prefix=CHECK-FIXES', '-strict-whitespace']' returned non-zero exit
status 1


--

********************
Testing Time: 13.07s
********************
Failing Tests (1):
    Clang Tools ::
clang-tidy/google-readability-namespace-comments-cxx17.cpp


  Expected Passes    : 673
  Unexpected Failures: 1
FAILED: tools/clang/tools/extra/test/CMakeFiles/check-clang-tools



Did you experience anything similar? Any ideas?

      - copied unchanged from r315059, clang-tools-extra/trunk/test/
> clang-tidy/google-readability-nested-namespace-comments.cpp
> Removed:
>     clang-tools-extra/trunk/test/clang-tidy/google-readability-
> nested-namespace-comments.cpp
>
> Removed: clang-tools-extra/trunk/test/clang-tidy/google-readability-
> nested-namespace-comments.cpp
> URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/
> trunk/test/clang-tidy/google-readability-nested-namespace-
> comments.cpp?rev=315059&view=auto
> ============================================================
> ==================
> --- 
> clang-tools-extra/trunk/test/clang-tidy/google-readability-nested-namespace-comments.cpp
> (original)
> +++ 
> clang-tools-extra/trunk/test/clang-tidy/google-readability-nested-namespace-comments.cpp
> (removed)
> @@ -1,15 +0,0 @@
> -// RUN: %check_clang_tidy %s google-readability-namespace-comments %t --
> -- -std=c++17
> -
> -namespace n1::n2 {
> -namespace n3 {
> -  // So that namespace is not empty.
> -  void f();
> -
> -// CHECK-MESSAGES: :[[@LINE+4]]:2: warning: namespace 'n3' not terminated
> with
> -// CHECK-MESSAGES: :[[@LINE-7]]:11: note: namespace 'n3' starts here
> -// CHECK-MESSAGES: :[[@LINE+2]]:3: warning: namespace 'n1::n2' not
> terminated with a closing comment [google-readability-namespace-comments]
> -// CHECK-MESSAGES: :[[@LINE-10]]:11: note: namespace 'n1::n2' starts here
> -}}
> -// CHECK-FIXES: }  // namespace n3
> -// CHECK-FIXES: }  // namespace n1::n2
> -
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits@lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
>
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to