mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 03:05:25 +08:00
19 lines
447 B
JavaScript
19 lines
447 B
JavaScript
import { acceptance } from "helpers/qunit-helpers";
|
|
|
|
acceptance("CustomHTML template", {
|
|
beforeEach() {
|
|
Ember.TEMPLATES['top'] = Ember.HTMLBars.compile(`<span class='top-span'>TOP</span>`);
|
|
},
|
|
|
|
afterEach() {
|
|
delete Ember.TEMPLATES['top'];
|
|
}
|
|
});
|
|
|
|
QUnit.test("renders custom template", assert => {
|
|
visit("/static/faq");
|
|
andThen(() => {
|
|
assert.equal(find('span.top-span').text(), 'TOP', 'it inserted the template');
|
|
});
|
|
});
|