discourse/test/javascripts/acceptance/user-card-test.js.es6

28 lines
597 B
Plaintext
Raw Normal View History

import { acceptance } from "helpers/qunit-helpers";
acceptance("User Card");
2017-06-14 13:57:58 -04:00
QUnit.test("card", assert => {
visit('/');
2017-06-14 13:57:58 -04:00
assert.ok(invisible('#user-card'), 'user card is invisible by default');
click('a[data-user-card=eviltrout]:first');
andThen(() => {
2017-06-14 13:57:58 -04:00
assert.ok(visible('#user-card'), 'card should appear');
});
});
QUnit.test("group card", assert => {
visit('/t/301/1');
assert.ok(invisible('#group-card'), 'user card is invisible by default');
click('a.mention-group:first');
andThen(() => {
assert.ok(visible('#group-card'), 'card should appear');
});
});