-
Notifications
You must be signed in to change notification settings - Fork 9
/
payment_experience_test.go
45 lines (37 loc) · 1 KB
/
payment_experience_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package paypal_test
import (
"github.com/smartwalle/paypal"
"testing"
)
func TestPayPal_CreateWebExperienceProfile(t *testing.T) {
var p = &paypal.WebProfiles{}
p.Name = "Test Name"
p.Presentation = &paypal.WebProfilesPresentation{}
p.Presentation.LogoImage = ""
p.Presentation.BrandName = ""
var result, err = client.CreateWebExperienceProfile(p)
if err != nil {
t.Fatal(err)
}
t.Log(result.Id, result.Presentation.LogoImage)
}
func TestPayPal_GetWebExperienceProfileList(t *testing.T) {
var result, err = client.GetWebExperienceProfileList()
if err != nil {
t.Fatal(err)
}
for _, profile := range result {
t.Logf(profile.Id, profile.Name)
}
}
func TestPayPal_DeleteWebExperienceProfile(t *testing.T) {
//var err = client.DeleteWebExperienceProfile("XP-6MSR-MERU-75MJ-SCXL")
//t.Log(err)
}
func TestPayPal_GetWebhookDetails(t *testing.T) {
var webhook, err = client.GetWebExperienceProfileDetails("XP-BEFQ-A67P-RNXQ-LJLM")
if err != nil {
t.Fatal(err)
}
t.Log(webhook.Id, webhook.Name)
}