44require 'open-uri'
55require 'net/http'
66
7- class Testvoiceit3 < Test ::Unit ::TestCase
7+ class TestVoiceIt3 < Test ::Unit ::TestCase
88
99 def download_file ( link , filename )
1010 File . open ( filename , "wb" ) do |saved_file |
@@ -17,9 +17,9 @@ def download_file(link, filename)
1717 def test_notification_url ( ) # test webhook URL's
1818 viapikey = ENV [ 'VIAPIKEY' ]
1919 viapitoken = ENV [ 'VIAPITOKEN' ]
20- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
20+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
2121 if ENV [ 'BOXFUSE_ENV' ] == 'voiceittest'
22- File . write ( ENV [ 'HOME' ] + '/' + 'platformVersion' , voiceit3 ::VERSION )
22+ File . write ( ENV [ 'HOME' ] + '/' + 'platformVersion' , VoiceIt3 ::VERSION )
2323 end
2424 myVoiceIt . addNotificationUrl ( 'https://voiceit.io' )
2525 assert_equal ( myVoiceIt . notification_url , "?notificationURL=https%3A%2F%2Fvoiceit.io" )
@@ -30,7 +30,7 @@ def test_notification_url() # test webhook URL's
3030 def test_users_groups ( ) # get all users, get all groups, create user, create group, add user to group, remove user from group, delete user delete group
3131 viapikey = ENV [ 'VIAPIKEY' ]
3232 viapitoken = ENV [ 'VIAPITOKEN' ]
33- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
33+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
3434 ret = JSON . parse ( myVoiceIt . createUser ( ) )
3535 assert_equal ( 201 , ret [ 'status' ] )
3636 assert_equal ( 'SUCC' , ret [ 'responseCode' ] )
@@ -93,7 +93,7 @@ def test_users_groups() # get all users, get all groups, create user, create gro
9393 def test_sub_accounts ( )
9494 viapikey = ENV [ 'VIAPIKEY' ]
9595 viapitoken = ENV [ 'VIAPITOKEN' ]
96- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
96+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
9797 ret = JSON . parse ( myVoiceIt . createManagedSubAccount ( 'Test' , 'Ruby' , '' , '' , '' ) )
9898 assert_equal ( 201 , ret [ 'status' ] )
9999 assert_equal ( 'SUCC' , ret [ 'responseCode' ] )
@@ -125,7 +125,7 @@ def test_video() # video enrollment, video verification, video identification, (
125125
126126 viapikey = ENV [ 'VIAPIKEY' ]
127127 viapitoken = ENV [ 'VIAPITOKEN' ]
128- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
128+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
129129 userId1 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
130130 userId2 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
131131 groupId = JSON . parse ( myVoiceIt . createGroup ( 'Sample Group Description' ) ) [ 'groupId' ]
@@ -257,7 +257,7 @@ def test_voice() # voice enrollment, voice verification, voice identification, (
257257
258258 viapikey = ENV [ 'VIAPIKEY' ]
259259 viapitoken = ENV [ 'VIAPITOKEN' ]
260- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
260+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
261261 userId1 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
262262 userId2 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
263263 groupId = JSON . parse ( myVoiceIt . createGroup ( 'Sample Group Description' ) ) [ 'groupId' ]
@@ -388,7 +388,7 @@ def test_face() # face enrollment, face verification
388388
389389 viapikey = ENV [ 'VIAPIKEY' ]
390390 viapitoken = ENV [ 'VIAPITOKEN' ]
391- myVoiceIt = voiceit3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
391+ myVoiceIt = VoiceIt3 . new ( viapikey , viapitoken , 'https://api.voiceit.io' )
392392 userId1 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
393393 userId2 = JSON . parse ( myVoiceIt . createUser ( ) ) [ 'userId' ]
394394 groupId = JSON . parse ( myVoiceIt . createGroup ( 'Sample Group Description' ) ) [ 'groupId' ]
0 commit comments