open-nomad/ui/tests/unit/components/tooltip-test.js
2022-01-20 09:54:56 -05:00

16 lines
532 B
JavaScript

import { module, test } from 'qunit';
import { setupTest } from 'ember-qunit';
import setupGlimmerComponentFactory from 'nomad-ui/tests/helpers/glimmer-factory';
module('Unit | Component | tooltip', function (hooks) {
setupTest(hooks);
setupGlimmerComponentFactory(hooks, 'tooltip');
test('long texts are ellipsised in the middle', function (assert) {
const tooltip = this.createComponent({
text: 'reeeeeeeeeeeeeeeeeally long text',
});
assert.equal(tooltip.text, 'reeeeeeeeeeeeee...long text');
});
});