-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[et] Lookup output filesystem path, not label #52248
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,6 +42,8 @@ void main() { | |
final List<CannedProcess> cannedProcesses = <CannedProcess>[ | ||
CannedProcess((List<String> command) => command.contains('desc'), | ||
stdout: fixtures.gnDescOutput()), | ||
CannedProcess((List<String> command) => command.contains('outputs'), | ||
stdout: 'display_list_unittests'), | ||
]; | ||
|
||
test('test command executes test', () async { | ||
|
@@ -83,7 +85,7 @@ void main() { | |
'//third_party/protobuf:protoc', | ||
]); | ||
expect(result, equals(1)); | ||
expect(testEnvironment.processHistory.length, lessThan(3)); | ||
expect(testEnvironment.processHistory.length, lessThan(6)); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Here and in the test above it: This expectation is impacted by implementation details of the test command. I don't think the number of processes executed is the right test, and instead we should just test that test processes are executed and that non-test processes are executed. I can send out a followup that fixes that. (I realise I also just added this test in a previous patch so I'm 100% to blame for this one :P) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, I think this count is too brittle. Better to have something like: expect(testEnvironment.processHistory, executed('gn desc')); |
||
expect(testEnvironment.processHistory.where((ExecutedProcess process) { | ||
return process.command[0].contains('protoc'); | ||
}), isEmpty); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed to a strictly greater-than check so that it matches the processHistory index we refer to, which will make it a little more obvious to people who modify this in the future.