From 8c7bf43129fe94922fd16e31aeebe0e560871e30 Mon Sep 17 00:00:00 2001 From: Deepjyoti Barman Date: Tue, 24 Sep 2024 19:43:09 +0530 Subject: [PATCH] fix: Failing tests related to checking invalid input in formFields This commit fixes a failing test case that was testing for an invalid input in formFields with non string value but since that type of value is now supported, the test case was broken. --- recipe/emailpassword/formFieldValidator_test.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipe/emailpassword/formFieldValidator_test.go b/recipe/emailpassword/formFieldValidator_test.go index ca915b33..869fb5ed 100644 --- a/recipe/emailpassword/formFieldValidator_test.go +++ b/recipe/emailpassword/formFieldValidator_test.go @@ -168,8 +168,8 @@ func TestInvalidAPIInputForFormFields(t *testing.T) { }, }, }, - expected: "formFields must be an array of objects containing id and value of type string", - fieldError: false, + expected: "Field is not optional", + fieldError: true, }, { input: map[string]interface{}{ @@ -179,8 +179,8 @@ func TestInvalidAPIInputForFormFields(t *testing.T) { }, }, }, - expected: "formFields must be an array of objects containing id and value of type string", - fieldError: false, + expected: "Field is not optional", + fieldError: true, }, { input: map[string]interface{}{