15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# File 'lib/ost-sdk-ruby/test/signature_generation_test.rb', line 15
def test_signature
test_obj_for_signature = {
a: nil,
b: [],
c: '',
d: ["", nil],
e: {},
k1: 125.45,
k2: 'Tejas',
aaaaa: {a: {a: "L21A", b: "L21B"}, b: {a: "L22A", b: "L22B"}, c: {a: "L23A", b: "L23B"}},
arrayValues: ["Hello", "There", "12345"],
garbage_str: "~!@#$%^&*()_+-= {}[]:\";'?/<>,. this is garbage"
}
test_endpoint = "/api/v2/users"
signature = signature_test_obj.get_signature_for_test(test_endpoint, test_obj_for_signature)
assert_equal(signature, "28664cdbc613b66835d7bcf825dce719fb8e0621992c291ba9bd1767c1c5560d")
end
|