Skip to content
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

Change duration formatting in niceDuration #1425

Merged
merged 2 commits into from
Jul 6, 2016
Merged

Change duration formatting in niceDuration #1425

merged 2 commits into from
Jul 6, 2016

Conversation

ddrone
Copy link
Contributor

@ddrone ddrone commented Jun 24, 2016

niceDuration used to display 61 second as "1:1" instead of "1:01". This patch fixes that and minute duration (which is 60 seconds last time I've checked) and adds couple of unit tests.

});

group('niceDuration()', () {
test('formats duration longer than a minute correctly', () {
Copy link
Member

Choose a reason for hiding this comment

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

Also test a duration that's exactly on the minute boundary.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@nex3
Copy link
Member

nex3 commented Jun 24, 2016

One additional test and I'll merge this in. Thanks for the fix!

@ddrone
Copy link
Contributor Author

ddrone commented Jul 4, 2016

Ping

@nex3
Copy link
Member

nex3 commented Jul 6, 2016

Sorry, I was on vacation all last week.

@nex3 nex3 merged commit 3a97279 into dart-lang:master Jul 6, 2016
@ddrone ddrone deleted the nice-duration branch July 6, 2016 19:47
@ddrone
Copy link
Contributor Author

ddrone commented Jul 6, 2016

No problem!

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.

2 participants