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
0fe29f58
Unverified
Commit
0fe29f58
authored
Oct 25, 2022
by
Jesús S Guerrero
Committed by
GitHub
Oct 25, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Raise an exception when invalid subshard name (#113222)
parent
563e0a4a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
1 deletion
+9
-1
test.dart
dev/bots/test.dart
+1
-1
test_test.dart
dev/bots/test/test_test.dart
+8
-0
No files found.
dev/bots/test.dart
View file @
0fe29f58
...
...
@@ -1972,7 +1972,7 @@ List<T> _selectIndexOfTotalSubshard<T>(List<T> tests, {String subshardKey = kSub
foundError
(<
String
>[
'
${red}
Invalid subshard name "
$subshardName
". Expected format "[int]_[int]" ex. "1_3"'
,
]);
return
<
T
>[]
;
throw
Exception
(
'Invalid subshard name:
$subshardName
'
)
;
}
// One-indexed.
final
int
index
=
int
.
parse
(
match
.
group
(
1
)!);
...
...
dev/bots/test/test_test.dart
View file @
0fe29f58
...
...
@@ -144,5 +144,13 @@ void main() {
expectExitCode
(
result
,
1
);
expect
(
result
.
stdout
,
contains
(
'Invalid subshard name'
));
});
test
(
'exits with code 255 when invalid SUBSHARD name'
,
()
async
{
final
ProcessResult
result
=
await
runScript
(
<
String
,
String
>{
'SHARD'
:
kTestHarnessShardName
,
'SUBSHARD'
:
'invalid_name'
},
);
expectExitCode
(
result
,
255
);
expect
(
result
.
stdout
,
contains
(
'Invalid subshard name'
));
});
});
}
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