You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The scope of testing here verifies the possibility of correctly uploading and downloading
38
-
a finite set of file types in a particular size range to [Permanent.org](Permanent.org) using [rclone](https://rclone.org/)
37
+
The scope of testing via the test cases documented below verifies the possibility of correctly uploading and downloading
38
+
a defined set of file types in a particular size range to [Permanent.org](Permanent.org) using [rclone](https://rclone.org/)
39
39
which talks to permanent using the [SFTP service](https://github.com/PermanentOrg/sftp-service)
40
40
41
41
### What file types are tested?
@@ -46,9 +46,9 @@ The scope of testing here verifies the possibility of correctly uploading and do
46
46
- Videos in `.mp4`, `.webm`, `.gifs` and `.3gp` common in mobile devices.
47
47
- Executable files in `.exe`, `.run`, `.sh`, `.dep` and extension-less bin executables.
48
48
49
-
### What test cases are covered?
49
+
##Test Cases?
50
50
51
-
####Challenging Names
51
+
### Challenging Names
52
52
53
53
Run `./generate-tree.py` to generate test data, which will be placed
54
54
in a new subdirectory named `test-tree/challenging-names`.
@@ -60,24 +60,24 @@ first, of course). See the long comment at the top of
60
60
[upload-test.sh](upload-test.sh) for information about what it's
61
61
trying to do and what problems we know about so far.
62
62
63
-
####Duplicates
63
+
### Duplicates
64
64
65
65
A duplicate is a file/folder with exactly the same name. Of course this is not possible on regular file systems but Permanent does support it.
66
66
There is a deduplication algorithm from Permanent that the `sftp-service` relies to ensure that files with identical names on Permanent won't be
67
67
be considered as the same on regular file systems.
68
68
69
-
#####How test duplicate
69
+
#### How test duplicate
70
70
71
71
- Create a folder in the test archive of the remote (permanent.org or permanent.dev depending on your test target) e.g 'duplicates'.
72
72
- Upload at least two copies of multiple identical files into the folder `duplicates` for example (`file.txt`, `file.txt`, `file.txt` and `photo.png`, `photo.png` ...)
73
73
- Run the download test script against the duplicate folder. In this case:
- Check download folder and ensure that results looks like:
80
+
- Check downloads folder in `test-tree/downloads` and ensure that results looks like:
81
81
82
82
*Result from `tree` program*
83
83
```
@@ -89,19 +89,19 @@ There is a deduplication algorithm from Permanent that the `sftp-service` relies
89
89
90
90
0 directories, 5 files
91
91
```
92
-
#####Multiple Identical Uploads
92
+
#### Multiple Identical Uploads
93
93
94
94
This test case captures what happens if you sync the same path with unchanged content multiples times.
95
95
96
-
#####How test identical uploads
96
+
#### How test identical uploads
97
97
98
98
- Generate challenging names if not generated earlier, see [Challenging Names](#challenging-names)
99
99
100
-
Run `./upload-test.py test-tree/challenging-names --only=414 --remote-dir=test-414 --log-file=duplicate-upload-log.txt --remote=prod --archive-path="/archives/QA (0a21-0000)/My Files/"`
100
+
Run `./upload-test.py test-tree/challenging-names --only=414 --remote-dir=test-414 --log-file=log-duplicate-upload.txt --remote=prod --archive-path="/archives/QA (0a21-0000)/My Files/"`
101
101
102
102
*Notice the use of the `--only` flag which specifies only files containing the number `414` should be uploaded, you can change this number to follow a string pattern in the generated challenging names but the provide example works just fine.*
103
103
104
-
#####Expected results
104
+
#### Expected results
105
105
106
106
-`rclone` should report `Sizes identical` and `Unchanged skipping`
107
107
@@ -111,8 +111,8 @@ Run `./upload-test.py test-tree/challenging-names --only=414 --remote-dir=test-4
111
111
```
112
112
- No duplicates should be be seen on Permanent UI.
113
113
114
-
#####Large uploads
115
-
######Uploads
114
+
#### Large uploads
115
+
##### Uploads
116
116
117
117
To test large file (`400MB` +) uploads, a couple of large files are required. Some ready-made test files can be downloaded via:
118
118
@@ -136,7 +136,43 @@ and then run `./special-files-downloader.py --my-source my_files.txt`
136
136
137
137
Once the files are on disk:
138
138
139
-
Run `./upload-test.py test-tree/special-files/large --remote-dir=large-files --log-file=large-files-log.txt --remote=prod --archive-path="/archives/QA (0a21-0000)/My Files/"`
139
+
Run `./upload-test.py test-tree/special-files/large --remote-dir=large-files --log-file=log-large-files.txt --remote=prod --archive-path="/archives/QA (0a21-0000)/My Files/"`
140
+
141
+
#### Nested folders/files
142
+
143
+
##### Uploading
144
+
145
+
We have a default nest of folders that goes down 4 levels.
146
+
147
+
Run `./upload-test.py test-tree/misc/nested/ --remote-dir=nested --log-file=log-nested.txt --remote=prod --archive-path="/archives/QA (0a21-0000)/My Files/"`
148
+
149
+
Verify in the Permanent UI that the folder set to remote dir `--remote-dir` in this case `nested` contains the nested folder with the following structure.
150
+
151
+
*Result from `tree` program*
152
+
153
+
```
154
+
test-tree/misc/nested/
155
+
├── nested-level-1
156
+
│ ├── nested-level-2
157
+
│ │ ├── nested-level-3
158
+
│ │ │ └── record-level-3.txt
159
+
│ │ └── record-level-2.txt
160
+
│ └── record-level-1.txt
161
+
└── record-level-0.txt
162
+
```
163
+
164
+
To test a nest with more levels, simply paste a nested folder structure inside `test-tree/misc/nested` or manually create more folder levels in the existing nest.
165
+
166
+
##### Downloading
167
+
168
+
*The steps in the upload section above must be completed before this step*
Check downloads folder in `test-tree/downloads` and ensure `downloads/nested` that results looks like the structured previous uploaded in the nested folder upload tests above.
0 commit comments