Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
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
abdullh.alsoleman
Front-End
Commits
ef563c48
Commit
ef563c48
authored
May 18, 2016
by
Ian Hickson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Handle stack traces that don't give column numbers (#4016)
parent
dacfdb64
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletion
+2
-1
stack_manipulation.dart
packages/flutter_test/lib/src/stack_manipulation.dart
+1
-1
stack_manipulation_test.dart
packages/flutter_test/test/stack_manipulation_test.dart
+1
-0
No files found.
packages/flutter_test/lib/src/stack_manipulation.dart
View file @
ef563c48
...
...
@@ -15,7 +15,7 @@ int reportExpectCall(StackTrace stack, StringBuffer information) {
final
RegExp
line0
=
new
RegExp
(
r'^#0 +fail \(.+\)$'
);
final
RegExp
line1
=
new
RegExp
(
r'^#1 +expect \(.+\)$'
);
final
RegExp
line2
=
new
RegExp
(
r'^#2 +expect \(.+\)$'
);
final
RegExp
line3
=
new
RegExp
(
r'^#3 +[^(]+ \((.+
):([0-9]+):[0-9]+
\)$'
);
final
RegExp
line3
=
new
RegExp
(
r'^#3 +[^(]+ \((.+
?):([0-9]+)(?::[0-9]+)?
\)$'
);
final
List
<
String
>
stackLines
=
stack
.
toString
().
split
(
'
\n
'
);
if
(
line0
.
firstMatch
(
stackLines
[
0
])
!=
null
&&
line1
.
firstMatch
(
stackLines
[
1
])
!=
null
&&
...
...
packages/flutter_test/test/stack_manipulation_test.dart
View file @
ef563c48
...
...
@@ -8,6 +8,7 @@ void main() {
test
(
'stack manipulation: reportExpectCall'
,
()
{
try
{
expect
(
false
,
isTrue
);
throw
'unexpectedly did not throw'
;
}
catch
(
e
,
stack
)
{
StringBuffer
information
=
new
StringBuffer
();
expect
(
reportExpectCall
(
stack
,
information
),
3
);
...
...
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