mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-01 19:17:58 +00:00
Better empty state copy
This commit is contained in:
committed by
Matthew Irish
parent
ab00bc8d96
commit
4767923a8f
@@ -1,6 +1,6 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { setupRenderingTest } from 'ember-qunit';
|
||||
import { render } from '@ember/test-helpers';
|
||||
import { render, find } from '@ember/test-helpers';
|
||||
import hbs from 'htmlbars-inline-precompile';
|
||||
|
||||
module('Integration | Component | empty-state', function(hooks) {
|
||||
@@ -16,11 +16,28 @@ module('Integration | Component | empty-state', function(hooks) {
|
||||
|
||||
// Template block usage:
|
||||
await render(hbs`
|
||||
{{#empty-state}}
|
||||
template block text
|
||||
{{#empty-state
|
||||
title="Empty State Title"
|
||||
message="This is the empty state message"
|
||||
}}
|
||||
Actions Link
|
||||
{{/empty-state}}
|
||||
`);
|
||||
|
||||
assert.equal(this.element.textContent.trim(), 'template block text');
|
||||
assert.equal(
|
||||
find('.empty-state-title').textContent.trim(),
|
||||
'Empty State Title',
|
||||
'renders empty state title'
|
||||
);
|
||||
assert.equal(
|
||||
find('.empty-state-message').textContent.trim(),
|
||||
'This is the empty state message',
|
||||
'renders empty state message'
|
||||
);
|
||||
assert.equal(
|
||||
find('.empty-state-actions').textContent.trim(),
|
||||
'Actions Link',
|
||||
'renders empty state actions'
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user