VirtualBox

Ignore:
Timestamp:
Mar 8, 2017 8:03:24 PM (8 years ago)
Author:
vboxsync
Message:

SharedFolders: Do RTAbsPath on folder roots, don't double convert to UTF-8 when calling RTFsQueryProperties, testcase workarounds for new absolute path handling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostServices/SharedFolders/testcase/tstSharedFolderService.cpp

    r63760 r65998  
    751751    RTTEST_CHECK_RC_OK(hTest, rc);
    752752    RTTEST_CHECK_MSG(hTest,
    753                      !strcmp(testRTFileOpenName, "/test/mapping/test/file"),
    754                      (hTest, "pszFilename=%s\n", testRTFileOpenName));
     753                     !strcmp(&testRTFileOpenName[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0],
     754                             "/test/mapping/test/file"),
     755                     (hTest, "pszFilename=%s\n", &testRTFileOpenName[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0]));
    755756    RTTEST_CHECK_MSG(hTest, testRTFileOpenFlags == 0x181,
    756757                     (hTest, "fOpen=%llu\n", LLUIFY(testRTFileOpenFlags)));
     
    781782    RTTEST_CHECK_RC_OK(hTest, rc);
    782783    RTTEST_CHECK_MSG(hTest,
    783                      !strcmp(testRTDirCreatePath, "/test/mapping/test/dir"),
    784                      (hTest, "pszPath=%s\n", testRTDirCreatePath));
     784                     !strcmp(&testRTDirCreatePath[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0],
     785                             "/test/mapping/test/dir"),
     786                     (hTest, "pszPath=%s\n", &testRTDirCreatePath[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0]));
    785787    RTTEST_CHECK_MSG(hTest,
    786                      !strcmp(testRTDirOpenName, "/test/mapping/test/dir"),
    787                      (hTest, "pszFilename=%s\n", testRTDirOpenName));
     788                     !strcmp(&testRTDirOpenName[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0],
     789                             "/test/mapping/test/dir"),
     790                     (hTest, "pszFilename=%s\n", &testRTDirOpenName[RTPATH_STYLE == RTPATH_STR_F_STYLE_DOS ? 2 : 0]));
    788791    RTTEST_CHECK_MSG(hTest, Result == SHFL_FILE_CREATED,
    789792                     (hTest, "Result=%d\n", (int) Result));
     
    924927    const uint32_t fMode = 0660;
    925928    SHFLFSOBJINFO Info;
    926     SHFLHANDLE Handle;
    927929    int rc;
    928930
     
    930932    Root = initWithWritableMapping(hTest, &svcTable, &svcHelpers,
    931933                                   "/test/mapping", "testname");
     934    SHFLHANDLE Handle = SHFL_HANDLE_NIL;
    932935    testRTFileOpenpFile = hcFile;
    933936    rc = createFile(&svcTable, Root, "/test/file", SHFL_CF_ACCESS_READ,
    934937                    &Handle, NULL);
    935     RTTEST_CHECK_RC_OK(hTest, rc);
     938    RTTEST_CHECK_RC_OK_RETV(hTest, rc);
     939
    936940    RT_ZERO(Info);
    937941    testRTFileQueryInfoFMode = fMode;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette