2017-02-24 07:56:25 +01:00
|
|
|
describe'system/get-api-keys' do
|
2021-11-05 21:06:08 +01:00
|
|
|
Scripts.logout()
|
2019-11-16 21:16:53 +01:00
|
|
|
Scripts.login($staff[:email], $staff[:password], true)
|
2017-01-13 21:06:49 +01:00
|
|
|
|
2019-11-16 21:16:53 +01:00
|
|
|
it 'should get all API keys' do
|
|
|
|
|
|
|
|
result = request('/system/get-api-keys', {
|
|
|
|
csrf_userid: $csrf_userid,
|
|
|
|
csrf_token: $csrf_token,
|
|
|
|
})
|
2017-01-13 21:06:49 +01:00
|
|
|
|
2019-11-16 21:16:53 +01:00
|
|
|
(result['status']).should.equal('success')
|
2020-10-14 20:08:14 +02:00
|
|
|
(result['data'][0]['name']).should.equal('APIkeyToTicketget')
|
|
|
|
(result['data'][1]['name']).should.equal('APIkey ticketnumber return')
|
|
|
|
(result['data'][2]['name']).should.equal('APIkey check tickets')
|
|
|
|
(result['data'][3]['name']).should.equal('APIkey user create')
|
|
|
|
(result['data'][4]['name']).should.equal('APIkey create tickets')
|
|
|
|
|
2019-11-16 21:16:53 +01:00
|
|
|
end
|
2017-01-13 21:06:49 +01:00
|
|
|
end
|