Skip to content

Commit

Permalink
chore: update utils test
Browse files Browse the repository at this point in the history
  • Loading branch information
nado1001 committed Nov 16, 2023
1 parent f0f8cb6 commit d80f241
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion src/tests/utils.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
import { describe, it, expect } from 'vitest'
import { getConfigValue, unquoteFromKeys, makeSdObject } from '../utils'
import {
addHyphen,
getConfigValue,
unquoteFromKeys,
makeSdObject
} from '../utils'

describe('addHyphen function', () => {
it('should add hyphen if the string does not end with hyphen', () => {
expect(addHyphen('hoge')).toEqual('hoge-')
})

it('should not add hyphen if the string ends with hyphen', () => {
expect(addHyphen('hoge-')).toEqual('hoge-')
})
})

describe('getConfigValue function', () => {
it('should return T if T is passed', () => {
Expand Down

0 comments on commit d80f241

Please sign in to comment.