diff --git a/tests/e2e/group_service_account_test.go b/tests/e2e/group_service_account_test.go new file mode 100644 index 00000000..373afb7a --- /dev/null +++ b/tests/e2e/group_service_account_test.go @@ -0,0 +1,20 @@ +package fivetran_test + +import ( + "context" + "fmt" + "testing" + + testutils "github.com/fivetran/go-fivetran/test_utils" +) + +func TestNewGroupServiceAccountE2E(t *testing.T) { + result, err := testutils.Client.NewGroupServiceAccount().GroupID(testutils.PredefinedGroupId).Do(context.Background()) + if err != nil { + t.Logf("%+v\n", result) + t.Error(err) + } + + testutils.AssertEqual(t, result.Code, "Success") + testutils.AssertEqual(t, result.Data.ServiceAccount, fmt.Sprintf("g-%v@fivetran-production.iam.gserviceaccount.com", testutils.PredefinedGroupId)) +} diff --git a/tests/e2e/group_ssh_key_test.go b/tests/e2e/group_ssh_key_test.go new file mode 100644 index 00000000..7f328565 --- /dev/null +++ b/tests/e2e/group_ssh_key_test.go @@ -0,0 +1,20 @@ +package fivetran_test + +import ( + "context" + "testing" + + testutils "github.com/fivetran/go-fivetran/test_utils" +) + +func TestNewGroupSshPublicKeyE2E(t *testing.T) { + result, err := testutils.Client.NewGroupSshPublicKey().GroupID(testutils.PredefinedGroupId).Do(context.Background()) + if err != nil { + t.Logf("%+v\n", result) + t.Error(err) + } + + testutils.AssertEqual(t, result.Code, "Success") + testutils.AssertNotEmpty(t, result.Data.PublicKey) + +}