summaryrefslogtreecommitdiff
path: root/spec/javascripts/vue_shared/components/lib/utils/dom_utils_spec.js
blob: 2388660b0c2e6a0ff77aaed3ce3742060bb8538e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
import * as domUtils from '~/vue_shared/components/lib/utils/dom_utils';

describe('domUtils', () => {
  describe('pixeliseValue', () => {
    it('should add px to a given Number', () => {
      expect(domUtils.pixeliseValue(12)).toEqual('12px');
    });

    it('should not add px to 0', () => {
      expect(domUtils.pixeliseValue(0)).toEqual('');
    });
  });
});