Skip to content

Commit 9f0969f

Browse files
committed
minor fix
1 parent cadc051 commit 9f0969f

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

test/session_helper.rb

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
MSG
1717

1818
module AuthType
19-
SERVICE_ACCOUNT = 'service'
19+
SERVICE_ACCOUNT = 'service_account'
2020
USER_ACCOUNT = 'user_account'
2121
end
2222

@@ -30,6 +30,14 @@ def auth_type
3030
def get_session
3131
unless @@session
3232
puts CREATE_ACCOUNT_MESSAGE
33+
case auth_type
34+
when AuthType::SERVICE_ACCOUNT
35+
puts "test execute by service_account mode. cannot create/delete files"
36+
when AuthType::USER_ACCOUNT
37+
puts "test execute by user_account mode"
38+
else
39+
raise "Unsupported GOOGLE_DRIVE_AUTH_TYPE: #{ENV['GOOGLE_DRIVE_AUTH_TYPE']}"
40+
end
3341
end
3442
account_path = File.join(File.dirname(__FILE__), 'account.yaml')
3543
config_path = File.join(File.dirname(__FILE__), 'config.json')

0 commit comments

Comments
 (0)