Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
benchmark
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
benchmark
Commits
440df36e
Commit
440df36e
authored
Jul 22, 2016
by
Eric Fiselier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve failure mode in complexity_test.cc
parent
1bd62bd0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
complexity_test.cc
test/complexity_test.cc
+11
-2
No files found.
test/complexity_test.cc
View file @
440df36e
...
...
@@ -36,18 +36,27 @@ struct TestCase {
CHECK
(
err_str
.
empty
())
<<
"Could not construct regex
\"
"
<<
regex
<<
"
\"
"
<<
" got Error: "
<<
err_str
;
std
::
string
near
=
"<EOF>"
;
std
::
string
line
;
bool
first
=
true
;
while
(
remaining_output
.
eof
()
==
false
)
{
CHECK
(
remaining_output
.
good
());
std
::
getline
(
remaining_output
,
line
);
// Keep the first line as context.
if
(
first
)
{
near
=
line
;
first
=
false
;
}
if
(
r
.
Match
(
line
))
return
;
CHECK
(
match_rule
!=
MR_Next
)
<<
"Expected line
\"
"
<<
line
<<
"
\"
to match regex
\"
"
<<
regex
<<
"
\"
"
;
<<
"
\"
to match regex
\"
"
<<
regex
<<
"
\"
"
<<
"
\n
started matching at line:
\"
"
<<
near
<<
"
\"
"
;
}
CHECK
(
remaining_output
.
eof
()
==
false
)
<<
"End of output reached before match for regex
\"
"
<<
regex
<<
"
\"
was found"
;
<<
"
\"
was found"
<<
"
\n
started matching at line:
\"
"
<<
near
<<
"
\"
"
;
}
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment