UNC & Long File Name
To test direct network browsing with UNC paths: Open a file, and use the Save As command to save it with a Long File Name (LFN) and UNC paths (for example, \\ServerName\MySubdirectory\MyLongFileName) to a standard server. It should be possible to save and retrieve files without specifically referencing a network drive letter.
Here is how to test whether your product properly handles LFNs. Basically, LFNs must do the following:
-
Allow plus signs, commas, semicolons, equal signs, and square brackets anywhere.
-
Not save leading or trailing spaces. (You can test for this by removing the name inserted into the Save As dialog box and typing “###test###” or similar text. The program should strip the spaces and add an extension, returning the file name “test.ext”.)
-
Not save question marks.
-
Support 255 characters (including the path and extension).
-
Save to a UNC path, such as \\Server\Directory\Filename.
-
You should test each of the allowed file names in the following list. When your application saves each file, it should add an extension and save it to the hard disk.For example, “test.” will save as “test..ext”.
- test
- test#test#test#test
- test#1234567890[on through 260]
|
- You should also test the following list of file names, which should save to the hard disk as indicated:
- test (saved as “test.ext”)
- ###test (saved as “test.ext”)
- test### (saved as “test.ext”)
- test#;#+#,#=#[#] (saved as “test#;#+#,#=#[#].ext”)
- \\folder#one\folder#two\folder#three\folder#four\file
|
LFN Verification for Utilities:
Run the utility (that is, your product), and manipulate several LFN files. Open these files with their LFN and with their 8.3 aliases, and make sure they still relate to the same file.
Check overall LFN file structure to make sure its integrity has not been damaged.