Thanks to visit codestin.com
Credit goes to github.com

Skip to content

More beautiful linear_gradient sample #96491

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

Closed
wants to merge 6 commits into from
Closed

Conversation

timsneath
Copy link
Contributor

@timsneath timsneath commented Jan 11, 2022

Tweak example so that it's more attractive to a design-oriented audience.

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 [Flutter Style Guide], including [Features we expect every widget to implement].
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • 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].

Tweaking example so that it's more attractive to a design-orientated audience
@flutter-dashboard flutter-dashboard bot added d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos documentation c: contributor-productivity Team-specific productivity, code health, technical debt. labels Jan 11, 2022
@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.

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.

@timsneath timsneath changed the title Update linear_gradient.0.dart More beautiful linear_gradient sample Jan 12, 2022
@goderbauer
Copy link
Member

Nice! I think we also need to adjust the description accompanying this example. It's not really "vertical window shades" we are showing now:

/// This sample draws a picture that looks like vertical window shades by having
.

@gspencergoog
Copy link
Contributor

We are trying to add tests as a requirement for all changes, including examples, so adding a test here would be good. We have examples of tests for examples in the examples/api/test dir.

@flutter-dashboard
Copy link

This pull request executed golden file tests, but it has not been updated in a while (20+ days). Test results from Gold expire after as many days, so this pull request will need to be updated with a fresh commit in order to get results from Gold.

For more guidance, visit Writing a golden file test for package:flutter.

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

@goderbauer
Copy link
Member

@gspencergoog @Piinks Do we support golden tests in API samples? This seems to be the first one added to the API samples and its failing...

Copy link
Contributor

@Piinks Piinks left a comment

Choose a reason for hiding this comment

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

We don't currently, but I think it would work if you include

return flutter_goldens.testExecutable(testMain);

in a flutter_test_config.dart file in examples/api/test, like in the flutter package.

https://github.com/flutter/flutter/blob/master/packages/flutter/test/flutter_test_config.dart

@gspencergoog
Copy link
Contributor

@goderbauer API Samples are just normal code now, so yes, they should support golden tests.

@gspencergoog
Copy link
Contributor

Oh, I didn't know packages needed configuring to make goldens work, but I guess that makes sense.

@Piinks
Copy link
Contributor

Piinks commented Feb 28, 2022

Oh, I didn't know packages needed configuring to make goldens work, but I guess that makes sense.

Just for if they want to use https://flutter-gold.skia.org/, this repo doesn't use the default golden file configuration

@goderbauer
Copy link
Member

I created #99298, which incorporates this PR and enables running golden tests for our API samples to make the newly added test pass. If that PR gets submitted, we can close this one.

@Piinks
Copy link
Contributor

Piinks commented Mar 2, 2022

Closing per #99298 (comment)

@Piinks Piinks closed this Mar 2, 2022
@tvolkert tvolkert deleted the timsneath-patch-1 branch March 24, 2022 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: contributor-productivity Team-specific productivity, code health, technical debt. d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants