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
324e6d9d
Unverified
Commit
324e6d9d
authored
Apr 07, 2022
by
Kate Lovett
Committed by
GitHub
Apr 07, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Re-enable Gold post-submit fail state (#101528)
parent
012952ba
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
46 deletions
+39
-46
flutter_goldens_test.dart
packages/flutter_goldens/test/flutter_goldens_test.dart
+38
-40
skia_client.dart
packages/flutter_goldens_client/lib/skia_client.dart
+1
-6
No files found.
packages/flutter_goldens/test/flutter_goldens_test.dart
View file @
324e6d9d
...
@@ -257,46 +257,44 @@ void main() {
...
@@ -257,46 +257,44 @@ void main() {
await
skiaClient
.
tryjobInit
();
await
skiaClient
.
tryjobInit
();
});
});
// TODO(Piinks): Re-enable once https://github.com/flutter/flutter/issues/100304
test
(
'throws for error state from imgtestAdd'
,
()
{
// is resolved.
final
File
goldenFile
=
fs
.
file
(
'/workDirectory/temp/golden_file_test.png'
)
// test('throws for error state from imgtestAdd', () {
..
createSync
(
recursive:
true
);
// final File goldenFile = fs.file('/workDirectory/temp/golden_file_test.png')
platform
=
FakePlatform
(
// ..createSync(recursive: true);
environment:
<
String
,
String
>{
// platform = FakePlatform(
'FLUTTER_ROOT'
:
_kFlutterRoot
,
// environment: <String, String>{
'GOLDCTL'
:
'goldctl'
,
// 'FLUTTER_ROOT': _kFlutterRoot,
},
// 'GOLDCTL' : 'goldctl',
operatingSystem:
'macos'
// },
);
// operatingSystem: 'macos'
// );
skiaClient
=
SkiaGoldClient
(
//
workDirectory
,
// skiaClient = SkiaGoldClient(
fs:
fs
,
// workDirectory,
process:
process
,
// fs: fs,
platform:
platform
,
// process: process,
httpClient:
fakeHttpClient
,
// platform: platform,
);
// httpClient: fakeHttpClient,
// );
const
RunInvocation
goldctlInvocation
=
RunInvocation
(
//
<
String
>[
// const RunInvocation goldctlInvocation = RunInvocation(
'goldctl'
,
// <String>[
'imgtest'
,
'add'
,
// 'goldctl',
'--work-dir'
,
'/workDirectory/temp'
,
// 'imgtest', 'add',
'--test-name'
,
'golden_file_test'
,
// '--work-dir', '/workDirectory/temp',
'--png-file'
,
'/workDirectory/temp/golden_file_test.png'
,
// '--test-name', 'golden_file_test',
'--passfail'
,
// '--png-file', '/workDirectory/temp/golden_file_test.png',
],
// '--passfail',
null
,
// ],
);
// null,
process
.
processResults
[
goldctlInvocation
]
=
ProcessResult
(
123
,
1
,
'Expected failure'
,
'Expected failure'
);
// );
process
.
fallbackProcessResult
=
ProcessResult
(
123
,
1
,
'Fallback failure'
,
'Fallback failure'
);
// process.processResults[goldctlInvocation] = ProcessResult(123, 1, 'Expected failure', 'Expected failure');
// process.fallbackProcessResult = ProcessResult(123, 1, 'Fallback failure', 'Fallback failure');
expect
(
//
skiaClient
.
imgtestAdd
(
'golden_file_test'
,
goldenFile
),
// expect(
throwsException
,
// skiaClient.imgtestAdd('golden_file_test', goldenFile),
);
// throwsException,
});
// );
// });
test
(
'correctly inits tryjob for luci'
,
()
async
{
test
(
'correctly inits tryjob for luci'
,
()
async
{
platform
=
FakePlatform
(
platform
=
FakePlatform
(
...
...
packages/flutter_goldens_client/lib/skia_client.dart
View file @
324e6d9d
...
@@ -212,12 +212,7 @@ class SkiaGoldClient {
...
@@ -212,12 +212,7 @@ class SkiaGoldClient {
..
writeln
(
'Debug information for Gold:'
)
..
writeln
(
'Debug information for Gold:'
)
..
writeln
(
'stdout:
${result.stdout}
'
)
..
writeln
(
'stdout:
${result.stdout}
'
)
..
writeln
(
'stderr:
${result.stderr}
'
);
..
writeln
(
'stderr:
${result.stderr}
'
);
// Temporarily print logs for issue diagnosis
throw
Exception
(
buf
.
toString
());
// ignore: avoid_print
print
(
buf
.
toString
());
// TODO(Piinks): Re-enable once https://github.com/flutter/flutter/issues/100304
// is resolved.
// throw Exception(buf.toString());
}
}
return
true
;
return
true
;
...
...
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