146 Commits

Author SHA1 Message Date
Jonah Williams
202d6b7994
[CI] remove check for exact golden files. (#166031)
Instead make sure at least 1 png is generated.

---------

Co-authored-by: Matan Lurey <matanlurey@users.noreply.github.com>
2025-03-28 03:19:24 +00:00
Matan Lurey
9e273d5e6e
Remove scenario_app/android and rename to ios_scenario_app. (#160992)
🚫 **BLOCKED** : Do not merge until
https://github.com/flutter/flutter/issues/161261 (additional test
coverage).

---

This PR eliminates (1) `scenario_app/android`, and all references to an
Android `scenario_app`, including documentation, CI configuration, build
rules, test runner, Android-side test application, and (2), to verify
and disambiguate the remains, renames the folder `ios_scenario_app`,
which is now accurate.

It also eliminates elements that were _only_ used in the Android-side
scenario_app, such as Firebase Test Lab uploading.

I would be open to doing this in phases if we thought it was better to
do so, but given its mostly a mechanical change (and by renaming the
directory, references can be checked merely by looking for
`/\bscenario_app/`, I believe this is safe to iterate on and eventually
merge after the holidays.

## Background

As of the merged mono-repo, there is no longer a requirement for the
engine to be testable as a standalone unit.

As an example,
[`%ENGINE%/testing/scenario_app`](3762f2e973/engine/src/flutter/testing/scenario_app),
which was intended to _emulate_ the Flutter framework (and some of
`flutter_tools` tooling), load the iOS and Android embedder, and run
various "scenarios" (which ran a combination of `dart:ui` code and
Android Java/iOS Obj-C) verifying golden-file screenshots.

Instead, it is now possible to write and run _real_ (full) Flutter apps
the same way that an end-user (or our own tests) would. One such example
is
[`dev/native_driver_test`](https://github.com/flutter/flutter/tree/master/dev/integration_tests/native_driver_test),
which is a full-fledged Flutter app, which uses standard tooling (i.e.
`flutter`), to test most of the same elements that previously were only
tested in the Android version of `scenario_app`.
2025-01-28 03:43:46 +00:00
Daco Harkes
09e3b52bdf [native assets] Consume NativeAssetsManifest.json (flutter/engine#56727)
This PR introduces a `NativeAssetsManifest.json` next to the `AssetManifest.json` and `FontManifest.json`. This removes the need for embedding the native assets mapping inside the kernel file and will enable decoupling native assets building and bundling from the kernel compilation in flutter tools. This will then allow us to remove dry-run from the build hook protocol.

(It also means all isolate groups will have the same native assets. However, since Flutter does not support `Isolate.spawnUri` from kernel files anyways, this is not a regression.)

This manifest is parsed eagerly on startup by the engine in a manner similar to how the font manifest is parsed. The manifest contents need to be available in the callback for resolving assets, which does not have access to the engine. Therefore the parsed manifest is `NativeAssetsManager` stored in the `IsolateGroupData`. The engine passes it in on isolate group creation, and the FFI callbacks access it from the isolate group data.

Issue:

* https://github.com/flutter/flutter/issues/154425

Related PRs:

* https://dart-review.googlesource.com/c/sdk/+/388161

Follow up work:

* This PR does not yet remove the engine callbacks registered via the dart_api that rely on kernel embedding. If we were to do that in this PR, it would require a manual roll of the engine into flutter/flutter with the PR that switches flutter_tools to emit the native assets manifest instead of embedding in kernel, and a manual roll into g3 to switch emitting a manifest instead of embedding in kernel. A TODO is left in the code for those callbacks to be removed.

## Testing

Most of this PR cannot be tested in isolation. The code in this PR is heavily exercised in the follow up flutter_tools PR which creates the `NativeAssetsManifest.json` and removes the embedding of native assets in kernel files.

* This PR adds a unit test for parsing the JSON manifest.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-11-21 18:01:46 +00:00
Chris Bracken
8582bd3b7a fml: delete scoped_nsobject.h,mm (flutter/engine#56382)
fml::scoped_nsobject and fml::scoped_nsprotocol classes are no longer
necessary now that the entire codebase has been migrated to ARC.

This also eliminates the fml_arc_unittests target which tests that code.
All references to that target in documentation, run_tests.py have been
removed. This target was used in various `et` build/query unit tests and
has been replaced with the fml_unittests target in those cases.

Issue: https://github.com/flutter/flutter/issues/137801
2024-11-05 12:59:05 -08:00
Jim Graham
9e747c2eb6 Delete last usages of MockCanvas test mechanism (flutter/engine#55840)
The MockCanvas API was originally used to test the output of rendering methods to match them against a reference set of "MockData" structures. This API has been superseded by just using a DisplayListBuilder to record reference operations and then to compare the resulting DisplayList objects.

This PR deletes the last remaining uses of MockCanvas as well as the mechanism itself.
2024-10-12 05:15:17 +00:00
Rafal Wachol
277967b295 [wiki] Fix link to engine dev setup (flutter/engine#54173)
Link to engine setup was broken so here's the fix
2024-07-29 22:39:16 +00:00
Matan Lurey
2565803818 Re-land #52859: Revamp the engine style guide, remove always_specify_types (flutter/engine#53223)
Based on the (internal) discussion around converging on using the official Dart style guide, the design discussion https://flutter.dev/go/use-dart-style-in-flutter-engine, and with the exception of the code that gets published under `dart:ui` (as that is user-facing, and we'd like to evolve the code style in conjunction with the framework), we're going to be (gradually) adopting the Dart style guide in `flutter/engine`.

For now, we:
- Remove `always_specify_types` (except for `lib/ui`, i.e. `dart:ui`)
- Re-enable `type_annotate_public_apis` (which is now relevant since the above is disabled)
- Announce our _intent_ to re-format and apply the Dart formatter (which we'll land in the near future)

---

I also took the opportunity to specify more about our style guide use in general, mostly to make it easier to understand our conventions, and also call out known problem areas (notably, our over-use of `shared_ptr` and `auto` in some cases). I am happy to split those up, but it was easier to make the markdown changes at once.

I also took @cbracken and folks advice and clarified directly that explicit types in Dart are _not_ bad (with examples).
2024-06-05 16:53:06 +00:00
John McDole
83a97eeaf1 Update CONTRIBUTING.md links (flutter/engine#53043)
`engine_dev_setup` moved to markdown

*Replace this paragraph with a description of what this PR is changing or adding, and why. Consider including before/after screenshots.*

*List which issues are fixed by this PR. You must list at least one issue.*

*If you had to change anything in the [flutter/tests] repo, include a link to the migration guide as per the [breaking change policy].*

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-05-29 22:36:43 +00:00
auto-submit[bot]
d810c59879 Reverts "Revamp the engine style guide, remove always_specify_types. (#52859)" (flutter/engine#52867)
Reverts: flutter/engine#52859
Initiated by: zanderso
Reason for reverting: This sort of change *is* in scope for a discussion at the Dash forum.
Original PR Author: matanlurey

Reviewed By: {cbracken, gaaclarke, johnmccutchan}

This change reverts the following previous change:
Based on the (internal) discussion around converging on using the official Dart style guide, with the exception of the code that gets published under `dart:ui`, as that is user-facing, and we'd like to evolve the code style in conjunction with the framework.

I also took the opportunity to specify more about our style guide use in general, mostly to make it easier to understand our conventions, and also call out known problem areas (notably, our over-use of `shared_ptr` and `auto` in some cases). I am happy to split those up, but it was easier to make the markdown changes at once.

I also took @cbracken and folks advice and clarified directly that explicit types in Dart are _not_ bad (with examples).
2024-05-16 02:51:50 +00:00
Matan Lurey
706817bd67 Revamp the engine style guide, remove always_specify_types. (flutter/engine#52859)
Based on the (internal) discussion around converging on using the official Dart style guide, with the exception of the code that gets published under `dart:ui`, as that is user-facing, and we'd like to evolve the code style in conjunction with the framework.

I also took the opportunity to specify more about our style guide use in general, mostly to make it easier to understand our conventions, and also call out known problem areas (notably, our over-use of `shared_ptr` and `auto` in some cases). I am happy to split those up, but it was easier to make the markdown changes at once.

I also took @cbracken and folks advice and clarified directly that explicit types in Dart are _not_ bad (with examples).
2024-05-16 01:07:17 +00:00
gabeschine
6b3f0f17dc Delete errant back-tick in CONTRIBUTING.md (flutter/engine#52324)
Delete an extra "`" in `CONTRIBUTING.md` in a code block.

No issues associated with this change.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2024-04-26 20:06:47 +00:00
Matan Lurey
1823aa6bc9 Clean up contributing formatting, add a Skia gold callout (flutter/engine#50828)
I am open to suggestions for other things to write under "Skia Gold".
2024-02-21 16:00:25 -08:00
gaaclarke
3296aee197 Updated CONTRIBUTING.md to have a testing section (flutter/engine#50469)
fixes https://github.com/flutter/flutter/issues/143087

## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

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

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-02-08 13:18:23 -08:00
gaaclarke
d5a2976258 Fixed CONTRIBUTING.md markdown lints (flutter/engine#50439)
## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide] and the [C++,
Objective-C, Java style guides].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I added new tests to check the change I am making or feature I am
adding, or the PR is [test-exempt]. See [testing the engine] for
instructions on writing and running engine tests.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I signed the [CLA].
- [x] All existing and new tests are passing.

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

<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#overview
[Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene
[test-exempt]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo
[C++, Objective-C, Java style guides]:
https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
[testing the engine]:
https://github.com/flutter/flutter/wiki/Testing-the-engine
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes
[Discord]: https://github.com/flutter/flutter/wiki/Chat
2024-02-07 10:27:07 -08:00
godofredoc
ee26f237c7 Remove cirrus build badge (flutter/engine#45103)
It was showing an error because the engine is not running cirrus tests anymore.

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
2023-08-25 15:14:06 +00:00
Chris Bracken
ef6d27f840 Formatting cleanup for CONTRIBUTING.md (flutter/engine#26080)
Re-wrap to 80 columns and use references for style guide links.

Unofficially, this is more about triggering a build than cleaning up.
2021-05-11 16:10:16 -07:00
Chris Bracken
bb7caf0bf9 Use 'For example' in place of 'e.g.' (flutter/engine#25486)
This avoids the awkward capitalisation 'E.g.' but more importantly
triggers a build with the latest recipe update, which includes Windows
UWP build products.
2021-04-07 22:15:28 -07:00
stuartmorgan
dae32b99fb Add a style note about Linux embedding style (flutter/engine#21819) 2020-10-15 10:47:01 -07:00
Kaushik Iska
e365786b0d kick build (flutter/engine#19575) 2020-07-07 09:05:29 -07:00
Kaushik Iska
abba8a2911 [fuchsia] Add additional contributing instructions for Googlers (flutter/engine#16337) 2020-02-03 11:46:06 -08:00
stuartmorgan
fa82f9abf1 Add style guide and formatting information (flutter/engine#11669)
Updates CONTRIBUTING.md with style guide links for the engine languages, as well as a note about auto-formatting.
2019-09-04 09:39:34 -07:00
Will Larche
a31aeb7b77 [Docs] Correcting link to contributing guide. (flutter/engine#8472) 2019-04-08 11:32:22 -07:00
Chris Bracken
ad9247dcfe Correct URL for Cirrus CI build status badge (flutter/engine#8054) 2019-03-05 18:30:39 -08:00
Chris Bracken
7c57f7d274 Minor cleanups to CONTRIBUTING.md (flutter/engine#8043)
This is really just in order to trigger a build. ci.chromium.org infra
had a short outage during our last build.
2019-03-05 12:07:07 -08:00
Ian Hickson
729424e086 Update the contributing guide (flutter/engine#6754)
Content has moved to the wiki.
2018-11-06 13:41:06 -08:00
Dan Field
b089d88a94 Update contributing.md for xcode_backend refactor notes (flutter/engine#6642)
* Update contributing.md for xcode_backend refactor notes
2018-10-25 11:29:55 -07:00
liyuqian
7357a29311 Remove travis directory (flutter/engine#5935)
This reflects that we no longer uses travis. Scripts are moved to ci folder.
2018-08-06 15:06:49 -07:00
liyuqian
d86db51c33 Mention that running git clone isn't necessary (flutter/engine#5816)
This copies https://github.com/flutter/engine/pull/5810 in order to use the newest format.sh to pass Travis.
2018-07-20 17:09:51 -07:00
matthew-carroll
85f553fb14 Android instructions format improvement in CONTRIBUTING.md (flutter/engine#5589) 2018-06-22 21:50:51 +00:00
Ian Hickson
127b1e271a Update CONTRIBUTING.md (flutter/engine#5444) 2018-06-01 13:24:53 -07:00
xster
77b1a14fde Correct ninja command instruction (flutter/engine#5032)
giving -C twice silently only builds one directory
2018-04-17 18:32:50 -07:00
Ian Hickson
e61f21b5be Breadcrumbs to the wiki (flutter/engine#5017)
* Breadcrumbs to the wiki

* Update README.md
2018-04-16 13:26:42 -07:00
xster
0739f028f4 Add hint to use ninja with goma (flutter/engine#4894) 2018-03-28 15:51:33 -07:00
Yegor
ee3f5ece99 CONTRIBUTING.md: explain the need for building host with non-host (flutter/engine#4863)
* CONTRIBUTING.md: explain the need for building host with non-host

* address comments

* locally-built
2018-03-23 17:50:52 -07:00
Florian Loitsch
d1a92cb0aa Fix missing backtick (flutter/engine#4788) 2018-03-15 11:25:07 +01:00
Ian Hickson
65a0ef4309 Remove mention of update-packages now that we pin them (flutter/engine#4500) 2018-01-02 17:16:20 -08:00
Ian Hickson
2e4166a960 Remove mention of adb from instructions (flutter/engine#4499)
* Remove mention of adb from instructions

This isn't a step we have our users do, so best that we don't do it either.

* Update CONTRIBUTING.md
2018-01-02 17:14:41 -08:00
Ian Hickson
d1defefec1 Updated depot_tools link (flutter/engine#4498) 2018-01-02 17:14:28 -08:00
Chris Bracken
8a9f21d076 Document that Xcode 9 is required to build the engine (flutter/engine#4469)
The engine build bots and engine development team now rely solely on
Xcode 9 to build the engine. The iOS 11 SDK is required (though we build
with deployment target of iOS 8) for several features such as safe area
inset support.
2017-12-18 10:00:19 -08:00
amirh
8b0815d5de Remove target-os specific gclient dependencies. (flutter/engine#4374)
As we anyway always recommend to set the target_os to android.
Also if you happen to not set the target_os to android it messes up the licenses script output.
2017-11-22 15:55:09 -08:00
Yegor
f49775667f CONTRIBUTING.md: suggest skipping intro (flutter/engine#4188)
...if the environment is already setup
2017-10-10 10:02:21 -07:00
Michael Goderbauer
11a9ee14fe Enforce clang-format for c-like sources on Travis (flutter/engine#4089)
* Enforce clang-format for c-like sources on Travis

* Edit CONTRIBUTING,md

* review feedback:

* ++

* ++

* ++
2017-09-12 15:42:37 -07:00
Michael Goderbauer
a8ea6bd4af Mention Goma for Googlers in CONTRIBUTING.md (flutter/engine#3946)
* Mention Goma for Googlers in CONTRIBUTING.md

* review comments
2017-08-02 13:49:27 -07:00
Abhishek Amit
5ec8f6d9f2 Fix android-cpu flag reference (flutter/engine#3943) 2017-08-01 14:02:28 -07:00
Michael Goderbauer
370fdd56a7 Add Windows support to CONTRIBUTING.md (flutter/engine#3825) 2017-06-23 17:58:57 -07:00
gspencergoog
1b33b0f50b Removed 'pub get' from the instructions (flutter/engine#3774)
* Removed 'pub get' from the instructions

According to Hixie, 'pub get' is abstracted into flutter packages upgrade, and so there shouldn't be a need to run pub get directly.

* Removed pub get lines entirely.
2017-06-14 16:28:21 -07:00
xster
7b2e3b2609 Link to lldb page in tip (flutter/engine#3593) 2017-04-18 10:48:46 -07:00
xster
3f70cb283a Add instructions for debugging engine with xcode (flutter/engine#3411) 2017-02-10 13:56:02 -08:00
xster
cceefabcb1 Add CONTRIBUTING instructions for simulator (flutter/engine#3407) 2017-02-09 23:06:11 -08:00
xster
04d16b0303 Document the need to sync the engine repo to avoid #8005 (flutter/engine#3403)
* Document the need to sync the engine repo to avoid #8005

* Flit gclient sync and git pull
2017-02-09 12:08:37 -08:00