Example #1
0
        public void UpdateProfileName_ItShouldUpdateProfileName_Success()
        {
            var userId = new ProfileNameView()
            {
                FirstNameEN  = "Meshal",
                SecondNameEN = "Alhammadi",
                ThirdNameEN  = "Alhammadi",
                LastNameEN   = "Alhammadi",
                FirstNameAR  = "مشعل",
                SecondNameAR = "الحمادي",
                ThirdNameAR  = "الحمادي",
                LastNameAR   = "الحمادي",
                UserId       = 4
            };

            var mm = _profileService.UpdateProfileNameAsync(userId).Result;

            Assert.IsTrue(mm.Success);
        }
Example #2
0
 /// <summary>
 /// Creates a success response.
 /// </summary>
 /// <param name="profileName">profileName view model.</param>
 /// <returns>Response.</returns>
 public ProfileResponse(ProfileNameView profileName) : this(true, ClientMessageConstant.Success, profileName)
 {
 }
Example #3
0
 private ProfileResponse(bool success, string message, ProfileNameView profileName) : base(success, message)
 {
     ProfileNameView = profileName;
 }
Example #4
0
        public async Task <IActionResult> UpdateProfileNameAsync([FromBody] ProfileNameView model)
        {
            var result = await _service.UpdateProfileNameAsync(model);

            return(Ok(result));
        }