-
Notifications
You must be signed in to change notification settings - Fork 692
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add tests and more validation for Read (#917)
* Add tests for reader and validate call in reader * Switch to a smaller test index and update correct hard coded SHA codes
- Loading branch information
1 parent
a8a1e48
commit 574278c
Showing
37 changed files
with
137 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file removed
BIN
-639 KB
...test_index1/blobs/sha256/1558143043601a425aa864511da238799b57fcf7d062d47044f6ddd0e04fe99a
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index1/blobs/sha256/26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79
Binary file not shown.
Binary file added
BIN
+157 Bytes
...test_index1/blobs/sha256/2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index1/blobs/sha256/3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index1/blobs/sha256/4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"config": {"digest": "sha256:93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569", "mediaType": "application/vnd.docker.container.image.v1+json", "size": 658}, "layers": [{"digest": "sha256:2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 157}, {"digest": "sha256:26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}, {"digest": "sha256:3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}], "mediaType": "application/vnd.docker.distribution.manifest.v2+json", "schemaVersion": 2} |
Binary file removed
BIN
-6.99 MB
...test_index1/blobs/sha256/5f5edd681dcbc3a4a9df93e200e59e1708031e65b2299970eabdc91a78cc8234
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index1/blobs/sha256/93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"architecture": "amd64", "author": "Bazel", "config": {}, "created": "1970-01-01T00:00:00Z", "history": [{"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}], "os": "linux", "rootfs": {"diff_ids": ["sha256:cfebe149e813482640cd5509f6c866bd83709a56aaa82bda6b05d633bd571591", "sha256:7bb7138798ce1c3019d6e2f306296ef3712a6ebd52368bf8ee3a2c97a6ffda41", "sha256:f2cc51d9aa9896cb1491b84be069511dccbe7140284c363c2223770aec9fcb74"], "type": "layers"}} |
1 change: 0 additions & 1 deletion
1
...test_index1/blobs/sha256/a0cfcd4cc98a67def7ce9a0c7644d1c415d56d6d44c4a079a447f7eafb253048
This file was deleted.
Oops, something went wrong.
21 changes: 0 additions & 21 deletions
21
...test_index1/blobs/sha256/edc3643ddf96d75032a55e240900b68b335186f1e5fea0a95af3b4cc96020b77
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+135 Bytes
...test_index2/blobs/sha256/26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79
Binary file not shown.
Binary file added
BIN
+157 Bytes
...test_index2/blobs/sha256/2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index2/blobs/sha256/3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index2/blobs/sha256/4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"config": {"digest": "sha256:93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569", "mediaType": "application/vnd.docker.container.image.v1+json", "size": 658}, "layers": [{"digest": "sha256:2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 157}, {"digest": "sha256:26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}, {"digest": "sha256:3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}], "mediaType": "application/vnd.docker.distribution.manifest.v2+json", "schemaVersion": 2} |
1 change: 1 addition & 0 deletions
1
...test_index2/blobs/sha256/93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"architecture": "amd64", "author": "Bazel", "config": {}, "created": "1970-01-01T00:00:00Z", "history": [{"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}], "os": "linux", "rootfs": {"diff_ids": ["sha256:cfebe149e813482640cd5509f6c866bd83709a56aaa82bda6b05d633bd571591", "sha256:7bb7138798ce1c3019d6e2f306296ef3712a6ebd52368bf8ee3a2c97a6ffda41", "sha256:f2cc51d9aa9896cb1491b84be069511dccbe7140284c363c2223770aec9fcb74"], "type": "layers"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"imageLayoutVersion": "1.0.0" | ||
} |
Binary file added
BIN
+135 Bytes
...test_index3/blobs/sha256/26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79
Binary file not shown.
Binary file added
BIN
+157 Bytes
...test_index3/blobs/sha256/2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index3/blobs/sha256/3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index3/blobs/sha256/93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"architecture": "amd64", "author": "Bazel", "config": {}, "created": "1970-01-01T00:00:00Z", "history": [{"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}], "os": "linux", "rootfs": {"diff_ids": ["sha256:cfebe149e813482640cd5509f6c866bd83709a56aaa82bda6b05d633bd571591", "sha256:7bb7138798ce1c3019d6e2f306296ef3712a6ebd52368bf8ee3a2c97a6ffda41", "sha256:f2cc51d9aa9896cb1491b84be069511dccbe7140284c363c2223770aec9fcb74"], "type": "layers"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"schemaVersion": 2, | ||
"manifests": [ | ||
{ | ||
"mediaType": "application/vnd.docker.distribution.manifest.v2+json", | ||
"size": 772, | ||
"digest": "sha256:4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"imageLayoutVersion": "1.0.0" | ||
} |
Binary file added
BIN
+135 Bytes
...test_index4/blobs/sha256/26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79
Binary file not shown.
Binary file added
BIN
+157 Bytes
...test_index4/blobs/sha256/2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index4/blobs/sha256/3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index4/blobs/sha256/4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"config": {"digest": "sha256:93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569", "mediaType": "application/vnd.docker.container.image.v1+json", "size": 658}, "layers": [{"digest": "sha256:2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 157}, {"digest": "sha256:26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}, {"digest": "sha256:3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}], "mediaType": "application/vnd.docker.distribution.manifest.v2+json", "schemaVersion": 2} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"schemaVersion": 2, | ||
"manifests": [ | ||
{ | ||
"mediaType": "application/vnd.docker.distribution.manifest.v2+json", | ||
"size": 772, | ||
"digest": "sha256:4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"imageLayoutVersion": "1.0.0" | ||
} |
Binary file added
BIN
+157 Bytes
...test_index5/blobs/sha256/2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca
Binary file not shown.
Binary file added
BIN
+135 Bytes
...test_index5/blobs/sha256/3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af
Binary file not shown.
1 change: 1 addition & 0 deletions
1
...test_index5/blobs/sha256/4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"config": {"digest": "sha256:93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569", "mediaType": "application/vnd.docker.container.image.v1+json", "size": 658}, "layers": [{"digest": "sha256:2cbd3e7a7cca7df9201e626abe080efe75e0588dda3c0188b1caf3a011f300ca", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 157}, {"digest": "sha256:26c668c40574f4fefe17ddfbc3a8744a5b83b8c00a03dff790cbe6a397f66d79", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}, {"digest": "sha256:3d4d5ef7eb586de880424d1613e36bc25a1617239ff81d8cf961c6481e6193af", "mediaType": "application/vnd.docker.image.rootfs.diff.tar.gzip", "size": 135}], "mediaType": "application/vnd.docker.distribution.manifest.v2+json", "schemaVersion": 2} |
1 change: 1 addition & 0 deletions
1
...test_index5/blobs/sha256/93cd8b73a9da05da6e1a9739e3610cbb0f19439d693931d3bf011d1d92b9e569
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"architecture": "amd64", "author": "Bazel", "config": {}, "created": "1970-01-01T00:00:00Z", "history": [{"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}, {"author": "Bazel", "created": "1970-01-01T00:00:00Z", "created_by": "bazel build ..."}], "os": "linux", "rootfs": {"diff_ids": ["sha256:cfebe149e813482640cd5509f6c866bd83709a56aaa82bda6b05d633bd571591", "sha256:7bb7138798ce1c3019d6e2f306296ef3712a6ebd52368bf8ee3a2c97a6ffda41", "sha256:f2cc51d9aa9896cb1491b84be069511dccbe7140284c363c2223770aec9fcb74"], "type": "layers"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"schemaVersion": 2, | ||
"manifests": [ | ||
{ | ||
"mediaType": "application/vnd.docker.distribution.manifest.v2+json", | ||
"size": 772, | ||
"digest": "sha256:4817a495758a70edcaa9ed6723cd927f21c44e2061313b03aaf5d5ae2c1bff46" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"imageLayoutVersion": "1.0.0" | ||
} |