Skip to content

Conversation

andrewkolos
Copy link
Contributor

@andrewkolos andrewkolos commented Mar 8, 2023

See #3420 (comment). Fixes a test broken by flutter/flutter#121322.

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the relevant style guides and ran the auto-formatter. (Unlike the flutter/flutter repo, the flutter/packages repo does use dart format.)
  • I signed the CLA.
  • The title of the PR starts with the name of the package surrounded by square brackets, e.g. [shared_preferences]
  • I listed at least one issue that this PR fixes in the description above.
  • I updated pubspec.yaml with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.
  • I updated CHANGELOG.md to add a description of the change, following repository CHANGELOG style.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat (don't just cc him here, he won't see it! He's on Discord!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

Copy link
Contributor

@cyanglaz cyanglaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stuartmorgan-g stuartmorgan-g changed the title add AssetManifest.bin to TestAssetBundle [flutter_markdown] add AssetManifest.bin to TestAssetBundle Mar 8, 2023
@stuartmorgan-g stuartmorgan-g added override: no versioning needed Override the check requiring version bumps for most changes override: no changelog needed Override the check requiring CHANGELOG updates for most changes labels Mar 8, 2023
@stuartmorgan-g
Copy link
Collaborator

No version/changelog needed: dev_dependencies changes are dev-only.

@andrewkolos
Copy link
Contributor Author

andrewkolos commented Mar 8, 2023

I'm afraid to merge since running flutter test against flutter_markdown locally results in some golden test failures with a 0.00% diff. Does this not mean the compared images are identical--or am I misinterpreting?

flutter test output
00:04 +167: /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart: Image should work with resources                                                                                                                              
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════
The following assertion was thrown while running async test code:
Golden "assets/images/golden/image_test/resource_asset_logo.png": Pixel test failed, 0.00% diff
detected.
Failure feedback can be found at
/Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/failures

When the exception was thrown, this was the stack:
#0      LocalFileComparator.compare (package:flutter_test/src/_goldens_io.dart:101:7)
<asynchronous suspension>
<asynchronous suspension>
(elided one frame from package:stack_trace)

The exception was caught asynchronously.
════════════════════════════════════════════════════════════════════════════════════════════════════
00:04 +167 -1: /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart: Image should work with resources [E]                                                                                                                       
  Test failed. See exception logs above.
  The test description was: should work with resources
  

To run this test again: /Users/andrewkolos/Documents/GitHub/flutter/bin/cache/dart-sdk/bin/dart test /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart -p vm --plain-name 'Image should work with resources'
00:05 +239 ~1 -1: /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart: Image custom image builder                                                                                                                              
══╡ EXCEPTION CAUGHT BY FLUTTER TEST FRAMEWORK ╞════════════════════════════════════════════════════
The following assertion was thrown while running async test code:
Golden "assets/images/golden/image_test/custom_builder_asset_logo.png": Pixel test failed, 0.00%
diff detected.
Failure feedback can be found at
/Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/failures

When the exception was thrown, this was the stack:
#0      LocalFileComparator.compare (package:flutter_test/src/_goldens_io.dart:101:7)
<asynchronous suspension>
<asynchronous suspension>
(elided one frame from package:stack_trace)

The exception was caught asynchronously.
════════════════════════════════════════════════════════════════════════════════════════════════════
00:05 +239 ~1 -2: /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart: Image custom image builder [E]                                                                                                                          
  Test failed. See exception logs above.
  The test description was: custom image builder
  

To run this test again: /Users/andrewkolos/Documents/GitHub/flutter/bin/cache/dart-sdk/bin/dart test /Users/andrewkolos/Documents/GitHub/blendthink/packages/packages/flutter_markdown/test/image_test.dart -p vm --plain-name 'Image custom image builder'
00:05 +318 ~4 -2: Some tests failed.  

@jonahwilliams
Copy link
Contributor

goldens are only valid on the machine they were generated on, more or less. I wouldn't worry about it

@andrewkolos andrewkolos added the autosubmit Merge PR when tree becomes green via auto submit App label Mar 8, 2023
@auto-submit auto-submit bot merged commit 4b03866 into flutter:main Mar 8, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Mar 9, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Mar 9, 2023
nploi pushed a commit to nploi/packages that referenced this pull request Jul 16, 2023
…3422)

[flutter_markdown] add AssetManifest.bin to TestAssetBundle
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App needs tests override: no changelog needed Override the check requiring CHANGELOG updates for most changes override: no versioning needed Override the check requiring version bumps for most changes p: flutter_markdown
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants