mirror of
https://github.com/datahub-project/datahub.git
synced 2025-07-29 04:20:00 +00:00
12 lines
508 B
TypeScript
12 lines
508 B
TypeScript
import { module, test } from 'qunit';
|
|
import { serializeStringArray } from '@datahub/utils/array/serialize-string';
|
|
|
|
module('Unit | Utility | array/serialize-string', function() {
|
|
test('it serializes the values in an array to a sorted string', function(assert) {
|
|
const arrayOfStrings = ['charmander', 'squirtle', 'bulbasaur'];
|
|
const expectedResult = 'bulbasaur,charmander,squirtle';
|
|
|
|
assert.equal(serializeStringArray(arrayOfStrings), expectedResult, 'Achieves the expected result');
|
|
});
|
|
});
|