Skip to content

Conversation

@CaseyHillers
Copy link
Contributor

Fixes #101773

@flutter-dashboard flutter-dashboard bot added the c: contributor-productivity Team-specific productivity, code health, technical debt. label May 10, 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 (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.

);
stdio.printStatus('Writing candidate branch...');
bool needsCommit = await framework.updateCandidateBranchVersion(state.releaseVersion);
bool needsCommit = await framework.updateCandidateBranchVersion(state.framework.candidateBranch);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not really sure how to test this. Any feedback would be helpful, but i'm not sure why the version was coming out as the branch in the test.

Copy link
Contributor

Choose a reason for hiding this comment

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

looking now....

Copy link
Contributor

Choose a reason for hiding this comment

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

You can insert the following snippet to the end of this test: https://github.com/flutter/flutter/blob/master/dev/conductor/core/test/next_test.dart#L737

        final File rcbVersionFile = fileSystem
            .directory(checkoutsParentDirectory)
            .childDirectory('framework')
            .childDirectory('bin')
            .childDirectory('internal')
            .childFile('release-candidate-branch.version');
        expect(rcbVersionFile.existsSync(), isTrue);
        expect(rcbVersionFile.readAsStringSync(), contains(candidateBranch));

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks! I did expect(stdio.stdout, contains('release-candidate-branch.version containing $candidateBranch')); to follow the format of the existing tests so if we refactor it's a bit easier.

Copy link
Contributor

@christopherfujino christopherfujino left a comment

Choose a reason for hiding this comment

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

LGTM

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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[conductor] Release candidate branch version is using version instead of branch

3 participants