Skip to content

Commit

Permalink
Have a few acceptance tests look for .displayMessage instead of .mess…
Browse files Browse the repository at this point in the history
…age for equality now
  • Loading branch information
philrenaud committed Sep 27, 2023
1 parent 432b765 commit 5daeec8
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .changelog/18595.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:improvement
ui: simplify presentation of task event times (10m2.230948s bceomes 10m2s etc.)
```
2 changes: 1 addition & 1 deletion ui/app/models/task-event.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,6 @@ function simplifyTimeMessage(message) {
m %= 60;

return `${h ? h + 'h' : ''}${h || m ? m + 'm' : ''}${s}s`;
}) || ''
}) || message
);
}
2 changes: 1 addition & 1 deletion ui/tests/acceptance/allocation-detail-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ module('Acceptance | allocation detail', function (hooks) {

assert.equal(taskRow.name, task.name, 'Name');
assert.equal(taskRow.state, task.state, 'State');
assert.equal(taskRow.message, event.message, 'Event Message');
assert.equal(taskRow.message, event.displayMessage, 'Event Message');
assert.equal(
taskRow.time,
moment(event.time / 1000000).format("MMM DD, 'YY HH:mm:ss ZZ"),
Expand Down
2 changes: 1 addition & 1 deletion ui/tests/acceptance/task-detail-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ module('Acceptance | task detail', function (hooks) {
'Event timestamp'
);
assert.equal(recentEvent.type, event.type, 'Event type');
assert.equal(recentEvent.message, event.message, 'Event message');
assert.equal(recentEvent.message, event.displayMessage, 'Event message');
});

test('when the allocation is not found, the application errors', async function (assert) {
Expand Down

0 comments on commit 5daeec8

Please sign in to comment.