blockchyp 2.9.6 → 2.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Makefile +1 -8
- data/README.md +479 -2442
- data/lib/blockchyp/version.rb +1 -1
- data/lib/blockchyp.rb +3 -217
- data/lib/blockchyp_client.rb +0 -78
- data/test/batch_history_test.rb +6 -10
- data/test/boolean_prompt_test.rb +4 -10
- data/test/cancel_payment_link_test.rb +7 -11
- data/test/capture_signature_test.rb +4 -10
- data/test/delete_customer_test.rb +6 -10
- data/test/delete_token_test.rb +7 -16
- data/test/gateway_timeout_test.rb +3 -10
- data/test/get_customer_test.rb +6 -10
- data/test/merchant_profile_test.rb +5 -10
- data/test/new_transaction_display_test.rb +4 -10
- data/test/pan_charge_test.rb +4 -10
- data/test/pan_enroll_test.rb +5 -16
- data/test/pan_preauth_test.rb +4 -10
- data/test/partial_refund_test.rb +5 -10
- data/test/search_customer_test.rb +6 -10
- data/test/send_payment_link_test.rb +6 -11
- data/test/simple_batch_close_test.rb +6 -10
- data/test/simple_capture_test.rb +6 -10
- data/test/simple_gift_activate_test.rb +4 -10
- data/test/simple_message_test.rb +4 -10
- data/test/simple_ping_test.rb +5 -11
- data/test/simple_refund_test.rb +5 -10
- data/test/simple_reversal_test.rb +6 -10
- data/test/simple_void_test.rb +6 -10
- data/test/terminal_charge_test.rb +5 -11
- data/test/terminal_clear_test.rb +4 -10
- data/test/terminal_ebt_balance_test.rb +4 -10
- data/test/terminal_ebt_charge_test.rb +4 -10
- data/test/terminal_enroll_test.rb +4 -10
- data/test/terminal_gift_card_balance_test.rb +4 -10
- data/test/terminal_keyed_charge_test.rb +4 -10
- data/test/terminal_manual_ebt_charge_test.rb +4 -10
- data/test/terminal_preauth_test.rb +4 -10
- data/test/terminal_status_test.rb +4 -10
- data/test/terminal_timeout_test.rb +3 -10
- data/test/terms_and_conditions_test.rb +4 -10
- data/test/test_helper.rb +2 -0
- data/test/text_prompt_test.rb +4 -10
- data/test/transaction_history_test.rb +6 -10
- data/test/update_customer_test.rb +5 -10
- data/test/update_transaction_display_test.rb +4 -10
- metadata +2 -46
- data/test/activate_terminal_test.rb +0 -45
- data/test/add_test_merchant_test.rb +0 -56
- data/test/deactivate_terminal_test.rb +0 -42
- data/test/delete_branding_asset_test.rb +0 -50
- data/test/delete_media_asset_test.rb +0 -53
- data/test/delete_queued_transaction_test.rb +0 -56
- data/test/delete_slide_show_test.rb +0 -50
- data/test/delete_survey_question_test.rb +0 -51
- data/test/delete_test_merchant_test.rb +0 -59
- data/test/empty_branding_asset_test.rb +0 -44
- data/test/empty_slide_show_test.rb +0 -45
- data/test/get_merchants_test.rb +0 -52
- data/test/invite_merchant_user_test.rb +0 -45
- data/test/link_token_test.rb +0 -56
- data/test/list_queued_transactions_test.rb +0 -55
- data/test/list_terminals_test.rb +0 -42
- data/test/media_asset_test.rb +0 -57
- data/test/media_test.rb +0 -42
- data/test/media_upload_test.rb +0 -52
- data/test/merchant_platforms_test.rb +0 -59
- data/test/merchant_users_test.rb +0 -42
- data/test/simple_locate_test.rb +0 -44
- data/test/slide_show_test.rb +0 -51
- data/test/slide_shows_test.rb +0 -49
- data/test/survey_question_test.rb +0 -48
- data/test/survey_questions_test.rb +0 -50
- data/test/survey_results_test.rb +0 -48
- data/test/tc_delete_template_test.rb +0 -51
- data/test/tc_entry_test.rb +0 -56
- data/test/tc_log_test.rb +0 -42
- data/test/tc_template_test.rb +0 -53
- data/test/tc_template_update_test.rb +0 -48
- data/test/tc_templates_test.rb +0 -42
- data/test/terminal_branding_test.rb +0 -42
- data/test/terminal_queued_transaction_test.rb +0 -51
- data/test/testdata/aviato.png +0 -0
- data/test/token_metadata_test.rb +0 -55
- data/test/unlink_token_test.rb +0 -56
- data/test/update_branding_asset_test.rb +0 -62
- data/test/update_merchant_platforms_test.rb +0 -61
- data/test/update_merchant_test.rb +0 -60
- data/test/update_slide_show_test.rb +0 -60
- data/test/update_survey_question_test.rb +0 -47
- data/test/upload_status_test.rb +0 -53
@@ -1,19 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Copyright 2019
|
3
|
+
# Copyright 2019 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
4
|
# governed by a license that can be found in the LICENSE file.
|
5
5
|
#
|
6
|
-
# This file was generated automatically
|
7
|
-
#
|
6
|
+
# This file was generated automatically. Changes to this file will be lost
|
7
|
+
# every time the code is regenerated.
|
8
8
|
|
9
9
|
require ::File.expand_path('test_helper', __dir__)
|
10
10
|
|
11
11
|
module BlockChyp
|
12
12
|
class TermsAndConditionsTest < TestCase
|
13
13
|
def test_terms_and_conditions
|
14
|
-
|
15
|
-
puts "Running test_terms_and_conditions..."
|
16
|
-
|
17
14
|
config = load_test_config
|
18
15
|
|
19
16
|
blockchyp = BlockChyp.new(
|
@@ -23,13 +20,9 @@ module BlockChyp
|
|
23
20
|
)
|
24
21
|
blockchyp.gateway_host = config[:gatewayHost]
|
25
22
|
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
23
|
|
28
24
|
test_delay(blockchyp, 'terms_and_conditions_test', config[:defaultTerminalName])
|
29
25
|
|
30
|
-
|
31
|
-
|
32
|
-
|
33
26
|
# Set request parameters
|
34
27
|
request = {
|
35
28
|
test: true,
|
@@ -42,6 +35,7 @@ module BlockChyp
|
|
42
35
|
}
|
43
36
|
|
44
37
|
response = blockchyp.terms_and_conditions(request)
|
38
|
+
|
45
39
|
assert_not_nil(response)
|
46
40
|
# response assertions
|
47
41
|
assert(response[:success])
|
data/test/test_helper.rb
CHANGED
data/test/text_prompt_test.rb
CHANGED
@@ -1,19 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Copyright 2019
|
3
|
+
# Copyright 2019 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
4
|
# governed by a license that can be found in the LICENSE file.
|
5
5
|
#
|
6
|
-
# This file was generated automatically
|
7
|
-
#
|
6
|
+
# This file was generated automatically. Changes to this file will be lost
|
7
|
+
# every time the code is regenerated.
|
8
8
|
|
9
9
|
require ::File.expand_path('test_helper', __dir__)
|
10
10
|
|
11
11
|
module BlockChyp
|
12
12
|
class TextPromptTest < TestCase
|
13
13
|
def test_text_prompt
|
14
|
-
|
15
|
-
puts "Running test_text_prompt..."
|
16
|
-
|
17
14
|
config = load_test_config
|
18
15
|
|
19
16
|
blockchyp = BlockChyp.new(
|
@@ -23,13 +20,9 @@ module BlockChyp
|
|
23
20
|
)
|
24
21
|
blockchyp.gateway_host = config[:gatewayHost]
|
25
22
|
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
23
|
|
28
24
|
test_delay(blockchyp, 'text_prompt_test', config[:defaultTerminalName])
|
29
25
|
|
30
|
-
|
31
|
-
|
32
|
-
|
33
26
|
# Set request parameters
|
34
27
|
request = {
|
35
28
|
test: true,
|
@@ -38,6 +31,7 @@ module BlockChyp
|
|
38
31
|
}
|
39
32
|
|
40
33
|
response = blockchyp.text_prompt(request)
|
34
|
+
|
41
35
|
assert_not_nil(response)
|
42
36
|
# response assertions
|
43
37
|
assert(response[:success])
|
@@ -1,19 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Copyright 2019
|
3
|
+
# Copyright 2019 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
4
|
# governed by a license that can be found in the LICENSE file.
|
5
5
|
#
|
6
|
-
# This file was generated automatically
|
7
|
-
#
|
6
|
+
# This file was generated automatically. Changes to this file will be lost
|
7
|
+
# every time the code is regenerated.
|
8
8
|
|
9
9
|
require ::File.expand_path('test_helper', __dir__)
|
10
10
|
|
11
11
|
module BlockChyp
|
12
12
|
class TransactionHistoryTest < TestCase
|
13
13
|
def test_transaction_history
|
14
|
-
|
15
|
-
puts "Running test_transaction_history..."
|
16
|
-
|
17
14
|
config = load_test_config
|
18
15
|
|
19
16
|
blockchyp = BlockChyp.new(
|
@@ -23,11 +20,8 @@ module BlockChyp
|
|
23
20
|
)
|
24
21
|
blockchyp.gateway_host = config[:gatewayHost]
|
25
22
|
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
23
|
|
24
|
+
test_delay(blockchyp, 'transaction_history_test', config[:defaultTerminalName])
|
31
25
|
|
32
26
|
# Set request parameters
|
33
27
|
setup_request = {
|
@@ -38,6 +32,7 @@ module BlockChyp
|
|
38
32
|
test: true,
|
39
33
|
transactionRef: uuid
|
40
34
|
}
|
35
|
+
|
41
36
|
response = blockchyp.charge(setup_request)
|
42
37
|
|
43
38
|
# Set request parameters
|
@@ -46,6 +41,7 @@ module BlockChyp
|
|
46
41
|
}
|
47
42
|
|
48
43
|
response = blockchyp.transaction_history(request)
|
44
|
+
|
49
45
|
assert_not_nil(response)
|
50
46
|
# response assertions
|
51
47
|
assert(response[:success])
|
@@ -1,19 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Copyright 2019
|
3
|
+
# Copyright 2019 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
4
|
# governed by a license that can be found in the LICENSE file.
|
5
5
|
#
|
6
|
-
# This file was generated automatically
|
7
|
-
#
|
6
|
+
# This file was generated automatically. Changes to this file will be lost
|
7
|
+
# every time the code is regenerated.
|
8
8
|
|
9
9
|
require ::File.expand_path('test_helper', __dir__)
|
10
10
|
|
11
11
|
module BlockChyp
|
12
12
|
class UpdateCustomerTest < TestCase
|
13
13
|
def test_update_customer
|
14
|
-
|
15
|
-
puts "Running test_update_customer..."
|
16
|
-
|
17
14
|
config = load_test_config
|
18
15
|
|
19
16
|
blockchyp = BlockChyp.new(
|
@@ -23,11 +20,8 @@ module BlockChyp
|
|
23
20
|
)
|
24
21
|
blockchyp.gateway_host = config[:gatewayHost]
|
25
22
|
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
23
|
|
24
|
+
test_delay(blockchyp, 'update_customer_test', config[:defaultTerminalName])
|
31
25
|
|
32
26
|
# Set request parameters
|
33
27
|
request = {
|
@@ -41,6 +35,7 @@ module BlockChyp
|
|
41
35
|
}
|
42
36
|
|
43
37
|
response = blockchyp.update_customer(request)
|
38
|
+
|
44
39
|
assert_not_nil(response)
|
45
40
|
# response assertions
|
46
41
|
assert(response[:success])
|
@@ -1,19 +1,16 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# Copyright 2019
|
3
|
+
# Copyright 2019 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
4
|
# governed by a license that can be found in the LICENSE file.
|
5
5
|
#
|
6
|
-
# This file was generated automatically
|
7
|
-
#
|
6
|
+
# This file was generated automatically. Changes to this file will be lost
|
7
|
+
# every time the code is regenerated.
|
8
8
|
|
9
9
|
require ::File.expand_path('test_helper', __dir__)
|
10
10
|
|
11
11
|
module BlockChyp
|
12
12
|
class UpdateTransactionDisplayTest < TestCase
|
13
13
|
def test_update_transaction_display
|
14
|
-
|
15
|
-
puts "Running test_update_transaction_display..."
|
16
|
-
|
17
14
|
config = load_test_config
|
18
15
|
|
19
16
|
blockchyp = BlockChyp.new(
|
@@ -23,13 +20,9 @@ module BlockChyp
|
|
23
20
|
)
|
24
21
|
blockchyp.gateway_host = config[:gatewayHost]
|
25
22
|
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
23
|
|
28
24
|
test_delay(blockchyp, 'update_transaction_display_test', config[:defaultTerminalName])
|
29
25
|
|
30
|
-
|
31
|
-
|
32
|
-
|
33
26
|
# Set request parameters
|
34
27
|
request = {
|
35
28
|
test: true,
|
@@ -56,6 +49,7 @@ module BlockChyp
|
|
56
49
|
}
|
57
50
|
|
58
51
|
response = blockchyp.update_transaction_display(request)
|
52
|
+
|
59
53
|
assert_not_nil(response)
|
60
54
|
# response assertions
|
61
55
|
assert(response[:success])
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: blockchyp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- BlockChyp
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-09-15 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|
@@ -23,37 +23,16 @@ files:
|
|
23
23
|
- lib/blockchyp/version.rb
|
24
24
|
- lib/blockchyp_client.rb
|
25
25
|
- lib/crypto_utils.rb
|
26
|
-
- test/activate_terminal_test.rb
|
27
|
-
- test/add_test_merchant_test.rb
|
28
26
|
- test/batch_history_test.rb
|
29
27
|
- test/boolean_prompt_test.rb
|
30
28
|
- test/cancel_payment_link_test.rb
|
31
29
|
- test/capture_signature_test.rb
|
32
|
-
- test/deactivate_terminal_test.rb
|
33
|
-
- test/delete_branding_asset_test.rb
|
34
30
|
- test/delete_customer_test.rb
|
35
|
-
- test/delete_media_asset_test.rb
|
36
|
-
- test/delete_queued_transaction_test.rb
|
37
|
-
- test/delete_slide_show_test.rb
|
38
|
-
- test/delete_survey_question_test.rb
|
39
|
-
- test/delete_test_merchant_test.rb
|
40
31
|
- test/delete_token_test.rb
|
41
|
-
- test/empty_branding_asset_test.rb
|
42
|
-
- test/empty_slide_show_test.rb
|
43
32
|
- test/gateway_timeout_test.rb
|
44
33
|
- test/get_customer_test.rb
|
45
|
-
- test/get_merchants_test.rb
|
46
34
|
- test/heartbeat_test.rb
|
47
|
-
- test/invite_merchant_user_test.rb
|
48
|
-
- test/link_token_test.rb
|
49
|
-
- test/list_queued_transactions_test.rb
|
50
|
-
- test/list_terminals_test.rb
|
51
|
-
- test/media_asset_test.rb
|
52
|
-
- test/media_test.rb
|
53
|
-
- test/media_upload_test.rb
|
54
|
-
- test/merchant_platforms_test.rb
|
55
35
|
- test/merchant_profile_test.rb
|
56
|
-
- test/merchant_users_test.rb
|
57
36
|
- test/new_transaction_display_test.rb
|
58
37
|
- test/pan_charge_test.rb
|
59
38
|
- test/pan_enroll_test.rb
|
@@ -64,24 +43,11 @@ files:
|
|
64
43
|
- test/simple_batch_close_test.rb
|
65
44
|
- test/simple_capture_test.rb
|
66
45
|
- test/simple_gift_activate_test.rb
|
67
|
-
- test/simple_locate_test.rb
|
68
46
|
- test/simple_message_test.rb
|
69
47
|
- test/simple_ping_test.rb
|
70
48
|
- test/simple_refund_test.rb
|
71
49
|
- test/simple_reversal_test.rb
|
72
50
|
- test/simple_void_test.rb
|
73
|
-
- test/slide_show_test.rb
|
74
|
-
- test/slide_shows_test.rb
|
75
|
-
- test/survey_question_test.rb
|
76
|
-
- test/survey_questions_test.rb
|
77
|
-
- test/survey_results_test.rb
|
78
|
-
- test/tc_delete_template_test.rb
|
79
|
-
- test/tc_entry_test.rb
|
80
|
-
- test/tc_log_test.rb
|
81
|
-
- test/tc_template_test.rb
|
82
|
-
- test/tc_template_update_test.rb
|
83
|
-
- test/tc_templates_test.rb
|
84
|
-
- test/terminal_branding_test.rb
|
85
51
|
- test/terminal_charge_test.rb
|
86
52
|
- test/terminal_clear_test.rb
|
87
53
|
- test/terminal_ebt_balance_test.rb
|
@@ -91,24 +57,14 @@ files:
|
|
91
57
|
- test/terminal_keyed_charge_test.rb
|
92
58
|
- test/terminal_manual_ebt_charge_test.rb
|
93
59
|
- test/terminal_preauth_test.rb
|
94
|
-
- test/terminal_queued_transaction_test.rb
|
95
60
|
- test/terminal_status_test.rb
|
96
61
|
- test/terminal_timeout_test.rb
|
97
62
|
- test/terms_and_conditions_test.rb
|
98
63
|
- test/test_helper.rb
|
99
|
-
- test/testdata/aviato.png
|
100
64
|
- test/text_prompt_test.rb
|
101
|
-
- test/token_metadata_test.rb
|
102
65
|
- test/transaction_history_test.rb
|
103
|
-
- test/unlink_token_test.rb
|
104
|
-
- test/update_branding_asset_test.rb
|
105
66
|
- test/update_customer_test.rb
|
106
|
-
- test/update_merchant_platforms_test.rb
|
107
|
-
- test/update_merchant_test.rb
|
108
|
-
- test/update_slide_show_test.rb
|
109
|
-
- test/update_survey_question_test.rb
|
110
67
|
- test/update_transaction_display_test.rb
|
111
|
-
- test/upload_status_test.rb
|
112
68
|
homepage: https://github.com/blockchyp/blockchyp-ruby
|
113
69
|
licenses:
|
114
70
|
- MIT
|
@@ -1,45 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class ActivateTerminalTest < TestCase
|
13
|
-
def test_activate_terminal
|
14
|
-
|
15
|
-
puts "Running test_activate_terminal..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
# Set request parameters
|
33
|
-
request = {
|
34
|
-
terminalName: 'Bad Terminal Code',
|
35
|
-
activationCode: 'XXXXXX'
|
36
|
-
}
|
37
|
-
|
38
|
-
response = blockchyp.activate_terminal(request)
|
39
|
-
assert_not_nil(response)
|
40
|
-
# response assertions
|
41
|
-
assert(!response[:success])
|
42
|
-
assert_equal('Invalid Activation Code', response[:error])
|
43
|
-
end
|
44
|
-
end
|
45
|
-
end
|
@@ -1,56 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class AddTestMerchantTest < TestCase
|
13
|
-
def test_add_test_merchant
|
14
|
-
|
15
|
-
puts "Running test_add_test_merchant..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
profile = config[:profiles][:partner]
|
30
|
-
blockchyp = BlockChyp.new(
|
31
|
-
profile[:apiKey],
|
32
|
-
profile[:bearerToken],
|
33
|
-
profile[:signingKey]
|
34
|
-
)
|
35
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
36
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
37
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
# Set request parameters
|
42
|
-
request = {
|
43
|
-
dbaName: 'Test Merchant',
|
44
|
-
companyName: 'Test Merchant'
|
45
|
-
}
|
46
|
-
|
47
|
-
response = blockchyp.add_test_merchant(request)
|
48
|
-
assert_not_nil(response)
|
49
|
-
# response assertions
|
50
|
-
assert(response[:success])
|
51
|
-
assert_equal('Test Merchant', response[:dbaName])
|
52
|
-
assert_equal('Test Merchant', response[:companyName])
|
53
|
-
assert(response[:visa])
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|
@@ -1,42 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class DeactivateTerminalTest < TestCase
|
13
|
-
def test_deactivate_terminal
|
14
|
-
|
15
|
-
puts "Running test_deactivate_terminal..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
# Set request parameters
|
33
|
-
request = {
|
34
|
-
terminalId: uuid
|
35
|
-
}
|
36
|
-
|
37
|
-
assert_raise RuntimeError do
|
38
|
-
blockchyp.deactivate_terminal(request)
|
39
|
-
end
|
40
|
-
end
|
41
|
-
end
|
42
|
-
end
|
@@ -1,50 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class DeleteBrandingAssetTest < TestCase
|
13
|
-
def test_delete_branding_asset
|
14
|
-
|
15
|
-
puts "Running test_delete_branding_asset..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
# Set request parameters
|
33
|
-
setup_request = {
|
34
|
-
notes: 'Empty Asset',
|
35
|
-
enabled: false
|
36
|
-
}
|
37
|
-
response = blockchyp.update_branding_asset(setup_request)
|
38
|
-
|
39
|
-
# Set request parameters
|
40
|
-
request = {
|
41
|
-
assetId: response[:id]
|
42
|
-
}
|
43
|
-
|
44
|
-
response = blockchyp.delete_branding_asset(request)
|
45
|
-
assert_not_nil(response)
|
46
|
-
# response assertions
|
47
|
-
assert(response[:success])
|
48
|
-
end
|
49
|
-
end
|
50
|
-
end
|
@@ -1,53 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class DeleteMediaAssetTest < TestCase
|
13
|
-
def test_delete_media_asset
|
14
|
-
|
15
|
-
puts "Running test_delete_media_asset..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
# Set request parameters
|
33
|
-
setup_request = {
|
34
|
-
fileName: 'aviato.png',
|
35
|
-
fileSize: 18843,
|
36
|
-
uploadId: uuid
|
37
|
-
}
|
38
|
-
file = File.open("test/testdata/aviato.png")
|
39
|
-
content = file.read
|
40
|
-
response = blockchyp.upload_media(setup_request, content)
|
41
|
-
|
42
|
-
# Set request parameters
|
43
|
-
request = {
|
44
|
-
mediaId: response[:id]
|
45
|
-
}
|
46
|
-
|
47
|
-
response = blockchyp.delete_media_asset(request)
|
48
|
-
assert_not_nil(response)
|
49
|
-
# response assertions
|
50
|
-
assert(response[:success])
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
@@ -1,56 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
# Copyright 2019-2022 BlockChyp, Inc. All rights reserved. Use of this code is
|
4
|
-
# governed by a license that can be found in the LICENSE file.
|
5
|
-
#
|
6
|
-
# This file was generated automatically by the BlockChyp SDK Generator.
|
7
|
-
# Changes to this file will be lost every time the code is regenerated.
|
8
|
-
|
9
|
-
require ::File.expand_path('test_helper', __dir__)
|
10
|
-
|
11
|
-
module BlockChyp
|
12
|
-
class DeleteQueuedTransactionTest < TestCase
|
13
|
-
def test_delete_queued_transaction
|
14
|
-
|
15
|
-
puts "Running test_delete_queued_transaction..."
|
16
|
-
|
17
|
-
config = load_test_config
|
18
|
-
|
19
|
-
blockchyp = BlockChyp.new(
|
20
|
-
config[:apiKey],
|
21
|
-
config[:bearerToken],
|
22
|
-
config[:signingKey]
|
23
|
-
)
|
24
|
-
blockchyp.gateway_host = config[:gatewayHost]
|
25
|
-
blockchyp.test_gateway_host = config[:testGatewayHost]
|
26
|
-
blockchyp.dashboard_host = config[:dashboardHost]
|
27
|
-
|
28
|
-
test_delay(blockchyp, 'delete_queued_transaction_test', config[:defaultTerminalName])
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
# Set request parameters
|
34
|
-
setup_request = {
|
35
|
-
terminalName: config[:defaultTerminalName],
|
36
|
-
transactionRef: uuid,
|
37
|
-
description: '1060 West Addison',
|
38
|
-
amount: '25.15',
|
39
|
-
test: true,
|
40
|
-
queue: true
|
41
|
-
}
|
42
|
-
response = blockchyp.charge(setup_request)
|
43
|
-
|
44
|
-
# Set request parameters
|
45
|
-
request = {
|
46
|
-
terminalName: config[:defaultTerminalName],
|
47
|
-
transactionRef: '*'
|
48
|
-
}
|
49
|
-
|
50
|
-
response = blockchyp.delete_queued_transaction(request)
|
51
|
-
assert_not_nil(response)
|
52
|
-
# response assertions
|
53
|
-
assert(response[:success])
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|