8 Commits

Author SHA1 Message Date
Juyeong Lee
13e993ed1a
Fix Typos (#19691) 2020-07-31 16:32:58 -07:00
Jason Simmons
905836d466
[web] Upgrade the test package to remove the dependency on package_resolver (#18135) 2020-05-05 10:57:02 -07:00
Yegor
f34bc65bee
use percent for golden diff rates; tighten the values (#16430) 2020-02-05 15:53:45 -08:00
Yegor
8c855dba98
fix text blurriness in HTML-rendered text (#15649)
* fix text blurriness in HTML-rendered text
2020-01-15 14:20:28 -08:00
Ferhat
3fd877715b
[web] Add basic color per vertex drawVertices API support (#13066)
* Implement basic drawVertices for BlendMode.srcOver and hairline rendering
* Implement maxDiffRate parameter for screenshot tests
2019-10-14 13:16:05 -07:00
David Iglesias
b875c7a5ff
Add web engine screenshot (scuba) tests (#12353)
* Import all golden files and tests from internal repo.
* Adapt test files to new screenshot API, and tweak some settings.

(Check PR to see individual changes to each file)

Fixes https://github.com/flutter/flutter/issues/40975
2019-09-20 09:00:55 -07:00
David Iglesias
d3c60acef8
More controls for Screenshot tests (for web) (#12284)
New features for golden tests (for web):

* Height/width of headless browser instance extracted to constants
* Remove border from the host iframe
* Added 'region' to matchGoldenFile, so screenshots can capture only
a subset of the viewport
* Added image-format-awareness (png) to screenshot comparison, so it
doesn't only look at raw bytes
* When a test fails, output a diff image alongside the unexpected
output.
2019-09-18 14:58:30 -07:00
Yegor
954f1988c5
Add custom test plugin that supports screenshot tests (#12079)
- Add a custom `PlatformPlugin` that spins up a server waiting for test to request a screenshot.
  - When a screenshot is requested the plugin talks to Chrome via the debug port, captures a screenshot, and compares it with a golden file
- This PR also adds proper CLI for `dev/test.dart` with an `ArgParser` for future extension into a proper developer tool for the team.
  - As a first couple of features, it adds `--debug` option to launch Chrome in debug mode, a `--target` option to choose a single test to run rather than all tests, and `--shard` option to choose a subset of tests to run.

Limitations:
 - While screenshot test will run on Cirrus, they are configured to not fail on Cirrus. Need to solve Chrome version skew.
 - Stack maps do not work yet (you get stacks, but they are nonsensical)
 - When requesting a single test, build_runner builds all tests anyway
 - Nothing but desktop Chrome is supported
 - Nothing but Linux is supported
 - There's no Chrome version pinning; currently assumed stable Chrome channel
2019-09-10 13:53:47 -07:00