+
+func TestIsOnboarded(t *testing.T) {
+ publicKey := "publicKey"
+ invokerUnderTest := APIInvokerEnrolmentDetails{
+ OnboardingInformation: OnboardingInformation{
+ ApiInvokerPublicKey: publicKey,
+ },
+ }
+
+ otherInvoker := APIInvokerEnrolmentDetails{
+ OnboardingInformation: OnboardingInformation{
+ ApiInvokerPublicKey: "otherPublicKey",
+ },
+ }
+ assert.False(t, invokerUnderTest.IsOnboarded(otherInvoker))
+
+ otherInvoker.OnboardingInformation.ApiInvokerPublicKey = publicKey
+ assert.True(t, invokerUnderTest.IsOnboarded(otherInvoker))
+}