Skip to content

176983 UI update#4949

Open
ievdokdm wants to merge 11 commits intoflutter:mainfrom
ievdokdm:176983-ui-update
Open

176983 UI update#4949
ievdokdm wants to merge 11 commits intoflutter:mainfrom
ievdokdm:176983-ui-update

Conversation

@ievdokdm
Copy link
Contributor

Add short sha to presubmit view header
Fix: flutter/flutter#176983

…view of dashborad on a header along with PR and author'
Task: Implement SHA Display in PreSubmitView Header
Summary: Updated the title construction logic in PreSubmitView to include the first 7 characters of the commit SHA. The header now follows the format 'PR flutter#123 by author (sha)' when loaded, 'PR flutter#123' when loading via PR, and '(sha)' when loading via SHA.
Files: dashboard/lib/views/presubmit_view.dart, dashboard/test/views/presubmit_view_test.dart
Why: Improves visibility of the specific commit being inspected in the CI results view.
…w of dashborad on a header along with PR and author' as complete
…n presubmit view of dashborad on a header along with PR and author'
…view of dashborad on a header along with PR and author'
@ievdokdm ievdokdm requested a review from jtmcdole February 17, 2026 22:11
];
}

final shortSha = (sha != null && sha!.length > 7)
Copy link
Member

Choose a reason for hiding this comment

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

This is not doing what you think it does - the substring is saying "Take the last 7 characters of the sha" not "take the first 7 characters". Here's a better way:

final shortSha = (sha == null) ? 'missing' : (sha.length > 7 ? sha.substring(0, 7) : sha);

createPreSubmitView({'repo': 'flutter', 'sha': 'abcdef123456'}),
);
// No pump() here to stay in loading state
expect(find.text('(f123456)'), findsOneWidget);
Copy link
Member

Choose a reason for hiding this comment

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

This should read abcdef1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement pr_dashboard_page.dart view in Flutter Dashboard

2 participants

Comments