ソースを参照

Revert "added tests for format=prometheus"

This reverts commit a4b78da15eae51f2f9e9b97942e034a0fe484be0.
Greg Junkietech 4 年 前
コミット
683e4e4c57

+ 3 - 12
metrixpp/tests/general/test_basic.py

@@ -227,6 +227,9 @@ class Test(tests.common.TestCase):
         runner = tests.common.ToolRunner('view', ['--format=xml'], prefix='xml')
         self.assertExec(runner.run())
         
+        runner = tests.common.ToolRunner('view', ['--format=prometheus'], prefix='prometheus')
+        self.assertExec(runner.run())
+        
         runner = tests.common.ToolRunner('collect',
                                          ['--std.code.complexity.cyclomatic'],
                                          prefix='nest',
@@ -247,18 +250,6 @@ class Test(tests.common.TestCase):
                                          use_prev=True)
         self.assertExec(runner.run())
 
-        runner = tests.common.ToolRunner('collect', ['--std.code.complexity.cyclomatic', '--std.code.lines.code'], save_prev=False)
-        self.assertExec(runner.run())
-
-        runner = tests.common.ToolRunner('view', ['--format=prometheus'], prefix='prometheus')
-        self.assertExec(runner.run())
-
-        runner = tests.common.ToolRunner('view',
-                                         ['--format=prometheus', '--ll=ERROR'],
-                                         prefix='prometheus_simple.cpp',
-                                         dirs_list=['./simple.cpp'])
-        self.assertExec(runner.run())
-
     def test_std_general_metrics(self):
 
         runner = tests.common.ToolRunner('collect',

+ 0 - 39
metrixpp/tests/general/test_basic/test_view_format_view_prometheus_simple.cpp_stdout.gold.txt

@@ -1,39 +0,0 @@
-std_code_lines_code {file="./simple.cpp", region="__global__"} 0
-
-std_code_lines_code {file="./simple.cpp", region="hmm"} 4
-
-std_code_lines_code {file="./simple.cpp", region="A"} 4
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="A"} 3
-std_code_lines_code {file="./simple.cpp", region="A"} 11
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="func"} 1
-std_code_lines_code {file="./simple.cpp", region="func"} 5
-
-std_code_lines_code {file="./simple.cpp", region="embeded"} 3
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="embeded"} 1
-std_code_lines_code {file="./simple.cpp", region="embeded"} 7
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="func_to_be_removed_in_new_sources"} 2
-std_code_lines_code {file="./simple.cpp", region="func_to_be_removed_in_new_sources"} 5
-
-std_code_lines_code {file="./simple.cpp", region="embeded"} 3
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="embeded"} 1
-std_code_lines_code {file="./simple.cpp", region="embeded"} 7
-
-std_code_complexity_cyclomatic {file="./simple.cpp", region="never"} 1
-std_code_lines_code {file="./simple.cpp", region="never"} 7
-
-std_code_complexity_cyclomatic_avg {file="./simple.cpp"} 1.5
-std_code_complexity_cyclomatic_min {file="./simple.cpp"} 1
-std_code_complexity_cyclomatic_max {file="./simple.cpp"} 3
-std_code_complexity_cyclomatic_total {file="./simple.cpp"} 9.0
-
-std_code_lines_code_avg {file="./simple.cpp"} 5.09090909
-std_code_lines_code_min {file="./simple.cpp"} 0
-std_code_lines_code_max {file="./simple.cpp"} 11
-std_code_lines_code_total {file="./simple.cpp"} 56.0
-
- 

+ 0 - 5
metrixpp/tests/general/test_basic/test_view_format_view_prometheus_stdout.gold.txt

@@ -3,9 +3,4 @@ std_code_complexity_cyclomatic_min {file="./"} 1
 std_code_complexity_cyclomatic_max {file="./"} 3
 std_code_complexity_cyclomatic_total {file="./"} 11.0
 
-std_code_lines_code_avg {file="./"} 4.875
-std_code_lines_code_min {file="./"} 0
-std_code_lines_code_max {file="./"} 11
-std_code_lines_code_total {file="./"} 78.0
 
-