Files
react-content-loader/tests/uid.js
Danilo Woznica 2d3baf7039 Feat/rtl (#104)
* Improv code

* feat(Wrap): RTL direction

* test(Tests): Code style

* test(RTL): Add test
2018-09-29 14:33:22 +01:00

18 lines
396 B
JavaScript
Executable File

import { expect } from "chai"
import uid from "../src/uid"
describe("unique id", () => {
const options = 100
const ids = new Array(options).fill(" ").map(item => uid())
const unique = Array.from(new Set(ids))
it(`should have ${options} diferents ids`, () => {
expect(unique).to.have.length(options)
})
it(`return a string`, () => {
expect(uid()).to.be.a("string")
})
})