summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2015-12-13 23:47:09 +0000
committerChris Wilson <chris+github@qwirx.com>2015-12-14 00:06:18 +0000
commit25155a7021a5145c3c2c38b0a2511f94a9243bf3 (patch)
treec78a546dd999569d16a1849fc54dc9cd04bb1296 /test
parente9ea5f21a90cca3623115a3c901d033b81f97eb6 (diff)
Remove asserts that caused tests to blow up when directory permissions were wrong
Diffstat (limited to 'test')
-rw-r--r--test/backupstore/testbackupstore.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/backupstore/testbackupstore.cpp b/test/backupstore/testbackupstore.cpp
index 00e16ad5..efdef230 100644
--- a/test/backupstore/testbackupstore.cpp
+++ b/test/backupstore/testbackupstore.cpp
@@ -2819,8 +2819,8 @@ bool test_open_files_with_limited_win32_permissions()
DWORD shareMode = FILE_SHARE_READ | FILE_SHARE_WRITE;
HANDLE h1 = CreateFileA(file, accessRights, shareMode,
- NULL, OPEN_ALWAYS, FILE_FLAG_BACKUP_SEMANTICS, NULL);
- assert(h1 != INVALID_HANDLE_VALUE);
+ NULL, OPEN_ALWAYS, // create file if it doesn't exist
+ FILE_FLAG_BACKUP_SEMANTICS, NULL);
TEST_THAT(h1 != INVALID_HANDLE_VALUE);
accessRights = FILE_READ_ATTRIBUTES |
@@ -2828,7 +2828,6 @@ bool test_open_files_with_limited_win32_permissions()
HANDLE h2 = CreateFileA(file, accessRights, shareMode,
NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL);
- assert(h2 != INVALID_HANDLE_VALUE);
TEST_THAT(h2 != INVALID_HANDLE_VALUE);
CloseHandle(h2);