# TEST: SECURITY-UM-26

## References

* [User Management](https://help.santesuite.org/installation/installation-1/deployment/installing-software/santedb-server/installation-qualification/security-administration-testing/test-cases-for-ui-1/user-management-tests/broken-reference)
* [TEST: SECURITY-UM-01](https://help.santesuite.org/installation/installation-1/deployment/installing-software/santedb-server/installation-qualification/security-administration-testing/test-cases-for-ui-1/user-management-tests/test-security-um-01)
* [TEST: SECURITY-UM-21](https://help.santesuite.org/installation/installation-1/deployment/installing-software/santedb-server/installation-qualification/security-administration-testing/test-cases-for-ui-1/user-management-tests/test-security-um-21)

## Discussion

SanteSuite allows users to register multiple **Address** objects each with State/Province, Country/District, City, Precinct/Borough, Street, and Postal/ZIP fields. Changing the **Address Type** for one of the Address Registration object form groups affects each form group heading.

## Pre-Conditions / Setup

1. User must be logged into an account with policies granted for creating users.
2. Follow the instructions from [TEST: SECURITY-UM-01](https://help.santesuite.org/installation/installation-1/deployment/installing-software/santedb-server/installation-qualification/security-administration-testing/test-cases-for-ui-1/user-management-tests/test-security-um-01) to create a new user -- applying any valid values for required fields.
3. Follow the instructions from [TEST: SECURITY-UM-21](https://help.santesuite.org/installation/installation-1/deployment/installing-software/santedb-server/installation-qualification/security-administration-testing/test-cases-for-ui-1/user-management-tests/test-security-um-21) to navigate to **Administration Panel / Security / Users / Edit User** for the newly created user.

## Actions/Steps

1\. Click the **User Profile** tab.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2GflPA0K75xp4zezV%2F-Me2HaZR0jkkwGdg-Tkk%2Fimage.png?alt=media\&token=dc443d97-a86d-42aa-9598-d876afca47fe)

2\. Click the pencil in the top right-hand corner of the **Profile** to edit the properties.&#x20;

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me1zRT-zkbwZyaZMImW%2F-Me2APtOBQvuT6ntvXN6%2Fimage.png?alt=media\&token=c2234b5f-fcac-4cfe-86da-7b283fe018fb)

3\. Click the **Address** tab.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2J-I2xyquzL0GVvea%2F-Me2KRpRTKi-8yjP2VPr%2Fimage.png?alt=media\&token=bd0fb469-fd41-46cd-b5a4-4a73484c122b)

4\. By default, the "Home Address" **Address Type** is selected and blank. Enter valid address field values.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2J-I2xyquzL0GVvea%2F-Me2LbYYD87JXm-nI9Dl%2Fimage.png?alt=media\&token=02a4b4c0-ac7a-474b-b220-1b5dc06e0288)

5\. Click the **Add** button in the bottom-right corner of the **Profile** to start adding a new Address Registration form group.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2LwcAkLeQ-E-LtPpO%2F-Me2MfbID13D_saZYzzF%2Fimage.png?alt=media\&token=129a947d-0476-4041-a901-09e52bedd5b7)

6\. Choose a different **Address Type** from the dropdown list (e.g. "Mailing Address").

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2LwcAkLeQ-E-LtPpO%2F-Me2NWZOdTHOgtoV6NRs%2Fimage.png?alt=media\&token=d16fddfd-916d-4bf1-9904-bc33cc2763b3)

7\. Enter valid **State/Province**, **Country/District**, **City**, **Precinct/Borough**, **Street**, and/or **Postal/ZIP** fields.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me2LwcAkLeQ-E-LtPpO%2F-Me2Oh3xhmXFcLlKzcmY%2Fimage.png?alt=media\&token=b6e173d4-8252-48f7-8534-6e0b997c92a8)

8\. Click the green checkmark to save the newly registered **Address** objects.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me1HQIY6P6INDRiiVvJ%2F-Me1WhhOu0AA-hqKmeMs%2Fimage.png?alt=media\&token=b1e421b8-1ec0-4e1b-8cd9-a40bfe25ca5c)

## Expected Behaviour

* Notice that **Remove** buttons appear below all but the first form group when there is more than one.
* Notice that **Address Registration** form group headings change according to the selected **Address Type** after selecting from the dropdown in step 6.
* Notice the red circle with exclamation mark next to the **Address** tab in step 6 when a Address Registration form group is blank. Clicking the green checkmark like in step 8 without providing a **Address Type** first like in step 6 has a result of nothing occurring.
* A toast message appears in the top-right corner of the window stating "User updated successfully" when the steps above are followed correctly.

![](https://3421852694-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LZ0_pjgTp_kx4hqTZ3a%2F-Me1zRT-zkbwZyaZMImW%2F-Me2FS-qYtLiDzU54RpY%2Fimage.png?alt=media\&token=8e3e3b29-6152-45e4-9ec4-ce5d08c60a9d)
