Exemple #1
0
        public async Task PrivacyLevelER_TestGetPrivacyLevel()
        {
            var privacyLevel = await PrivacyLevelER.GetPrivacyLevelER(1);

            Assert.NotNull(privacyLevel);
            Assert.IsType <PrivacyLevelER>(privacyLevel);
        }
Exemple #2
0
        public async Task PrivacyLevelER_TestDeleteObjectFromDatabase()
        {
            const int ID_TO_DELETE = 99;

            await PrivacyLevelER.DeletePrivacyLevelER(ID_TO_DELETE);

            await Assert.ThrowsAsync <DataPortalException>(() => PrivacyLevelER.GetPrivacyLevelER(ID_TO_DELETE));
        }
Exemple #3
0
        public async Task PrivacyLevelER_TestUpdateExistingPrivacyLevelER()
        {
            var privacyLevel = await PrivacyLevelER.GetPrivacyLevelER(1);

            privacyLevel.Notes = "These are updated Notes";

            var result = await privacyLevel.SaveAsync();

            Assert.NotNull(result);
            Assert.Equal("These are updated Notes", result.Notes);
        }