Skip to content

Commit

Permalink
Update param2Obj.spec.js
Browse files Browse the repository at this point in the history
  • Loading branch information
mayunhai authored Apr 13, 2020
1 parent ceb70e9 commit 32ad600
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/unit/utils/param2Obj.spec.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import { param2Obj } from '@/utils/index.js'
describe('Utils:param2Obj', () => {
const url = 'https://github.com/PanJiaChen/vue-element-admin?name=bill&age=29&sex=1&field=dGVzdA=='
const url = 'https://github.com/PanJiaChen/vue-element-admin?name=bill&age=29&sex=1&field=dGVzdA==&key=%E6%B5%8B%E8%AF%95'

it('param2Obj test', () => {
expect(param2Obj(url)).toEqual({
name: 'bill',
age: '29',
sex: '1',
field: window.btoa('test')
field: window.btoa('test'),
key: '测试'
})
})
})

0 comments on commit 32ad600

Please sign in to comment.