func (s *TestUsersSuite) TestUpdateUserOKWithoutContextInfo() {

	// given
	user := s.createRandomUser("TestUpdateUserOKWithoutContextInfo")
	identity := s.createRandomIdentity(user, account.KeycloakIDP)
	_, result := test.ShowUsersOK(s.T(), nil, nil, s.controller, identity.ID.String())
	assert.Equal(s.T(), identity.ID.String(), *result.Data.ID)
	assert.Equal(s.T(), user.FullName, *result.Data.Attributes.FullName)
	assert.Equal(s.T(), user.ImageURL, *result.Data.Attributes.ImageURL)
	assert.Equal(s.T(), identity.ProviderType, *result.Data.Attributes.ProviderType)
	assert.Equal(s.T(), identity.Username, *result.Data.Attributes.Username)
	// when
	newEmail := "updated-" + uuid.NewV4().String() + "@email.com"
	newFullName := "TestUpdateUserOKWithoutContextInfo"
	newImageURL := "http://new.image.io/imageurl"
	newBio := "new bio"
	newProfileURL := "http://new.profile.url/url"
	secureService, secureController := s.SecuredController(identity)

	updateUsersPayload := createUpdateUsersPayloadWithoutContextInformation(&newEmail, &newFullName, &newBio, &newImageURL, &newProfileURL)
	test.UpdateUsersOK(s.T(), secureService.Context, secureService, secureController, updateUsersPayload)
}
/*
	Pass no contextInformation and no one complains.
	This is as per general service behaviour.
*/
Pass no contextInformation and no one complains.
This is as per general service behaviour.
/ * Pass no contextInformation and no one complains . This is as per general service behaviour . * /
func (s *TestUsersSuite) TestUpdateUserOKWithoutContextInfo() {
	user := s.createRandomUser("TestUpdateUserOKWithoutContextInfo")
	identity := s.createRandomIdentity(user, account.KeycloakIDP)
	_, result := test.ShowUsersOK(s.T(), nil, nil, s.controller, identity.ID.String())
	assert.Equal(s.T(), identity.ID.String(), *result.Data.ID)
	assert.Equal(s.T(), user.FullName, *result.Data.Attributes.FullName)
	assert.Equal(s.T(), user.ImageURL, *result.Data.Attributes.ImageURL)
	assert.Equal(s.T(), identity.ProviderType, *result.Data.Attributes.ProviderType)
	assert.Equal(s.T(), identity.Username, *result.Data.Attributes.Username)
	newEmail := "updated-" + uuid.NewV4().String() + "@email.com"
	newFullName := "TestUpdateUserOKWithoutContextInfo"
	newImageURL := "http://new.image.io/imageurl"
	newBio := "new bio"
	newProfileURL := "http://new.profile.url/url"
	secureService, secureController := s.SecuredController(identity)
	updateUsersPayload := createUpdateUsersPayloadWithoutContextInformation(&newEmail, &newFullName, &newBio, &newImageURL, &newProfileURL)
	test.UpdateUsersOK(s.T(), secureService.Context, secureService, secureController, updateUsersPayload)
}
func ( s * TestUsersSuite ) TestUpdateUserOKWithoutContextInfo ( ) { user := s . createRandomUser ( " " ) identity := s . createRandomIdentity ( user , account . KeycloakIDP ) _ , result := test . ShowUsersOK ( s . T ( ) , nil , nil , s . controller , identity . ID . String ( ) ) assert . Equal ( s . T ( ) , identity . ID . String ( ) , * result . Data . ID ) assert . Equal ( s . T ( ) , user . FullName , * result . Data . Attributes . FullName ) assert . Equal ( s . T ( ) , user . ImageURL , * result . Data . Attributes . ImageURL ) assert . Equal ( s . T ( ) , identity . ProviderType , * result . Data . Attributes . ProviderType ) assert . Equal ( s . T ( ) , identity . Username , * result . Data . Attributes . Username ) newEmail := " " + uuid . NewV4 ( ) . String ( ) + " " newFullName := " " newImageURL := " " newBio := " " newProfileURL := " " secureService , secureController := s . SecuredController ( identity ) updateUsersPayload := createUpdateUsersPayloadWithoutContextInformation ( & newEmail , & newFullName , & newBio , & newImageURL , & newProfileURL ) test . UpdateUsersOK ( s . T ( ) , secureService . Context , secureService , secureController , updateUsersPayload ) }
Pass no contextInformation and no one complains.
Pass no contextInformation and no one complains .
// given // when