Skip to content

Commit 19ede27

Browse files
committed
test: update snapshots
1 parent 29de0d5 commit 19ede27

4 files changed

Lines changed: 93 additions & 1 deletion

File tree

cmd/osv-scanner/scan/image/__snapshots__/command_test.snap

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1202,6 +1202,33 @@ You can also view the full vulnerability list in your terminal with: `osv-scanne
12021202
12031203
---
12041204
1205+
[TestCommand_OCIImage/scanning_ubuntu_image_with_homebrew_extractor - 1]
1206+
Scanning local image tarball "./testdata/test-ubuntu-homebrew.tar"
1207+
1208+
1209+
Container Scanning Result (Ubuntu 22.04.5 LTS):
1210+
Total 1 package affected by 3 known vulnerabilities (1 Critical, 1 High, 1 Medium, 0 Low, 0 Unknown) from 1 ecosystem.
1211+
0 vulnerabilities can be fixed.
1212+
1213+
1214+
GIT
1215+
+------------------------------------------------------------------------------------------------------------------------------------------------------+
1216+
| Source:os:/home/linuxbrew/.linuxbrew/Cellar/cjson/1.7.17/INSTALL_RECEIPT.json |
1217+
+-------------------------------------+-------------------+------------------+------------+-------------------------+------------------+---------------+
1218+
| SOURCE PACKAGE | INSTALLED VERSION | FIX AVAILABLE | VULN COUNT | BINARY PACKAGES (COUNT) | INTRODUCED LAYER | IN BASE IMAGE |
1219+
+-------------------------------------+-------------------+------------------+------------+-------------------------+------------------+---------------+
1220+
| https://github.com/DaveGamble/cJSON | 1.7.17 | No fix available | 3 | | # 13 Layer | -- |
1221+
+-------------------------------------+-------------------+------------------+------------+-------------------------+------------------+---------------+
1222+
1223+
For the most comprehensive scan results, we recommend using the HTML output: `osv-scanner scan image --serve <image_name>`.
1224+
You can also view the full vulnerability list in your terminal with: `osv-scanner scan image --format vertical <image_name>`.
1225+
1226+
---
1227+
1228+
[TestCommand_OCIImage/scanning_ubuntu_image_with_homebrew_extractor - 2]
1229+
1230+
---
1231+
12051232
[TestCommand_OCIImage_JSONFormat/Scanning_python_image_with_some_packages - 1]
12061233
{
12071234
"results": [

cmd/osv-scanner/scan/image/testdata/cassettes/TestCommand_OCIImage.yaml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15602,3 +15602,62 @@ interactions:
1560215602
status: 200 OK
1560315603
code: 200
1560415604
duration: 0s
15605+
- request:
15606+
proto: HTTP/1.1
15607+
proto_major: 1
15608+
proto_minor: 1
15609+
content_length: 171
15610+
host: api.osv.dev
15611+
body: |
15612+
{
15613+
"queries": [
15614+
{
15615+
"package": {
15616+
"ecosystem": "GIT",
15617+
"name": "https://github.com/davegamble/cjson"
15618+
},
15619+
"version": "1.7.17"
15620+
}
15621+
]
15622+
}
15623+
headers:
15624+
Content-Type:
15625+
- application/json
15626+
X-Test-Name:
15627+
- TestCommand_OCIImage/scanning_ubuntu_image_with_homebrew_extractor
15628+
url: https://api.osv.dev/v1/querybatch
15629+
method: POST
15630+
response:
15631+
proto: HTTP/1.1
15632+
proto_major: 1
15633+
proto_minor: 1
15634+
content_length: 220
15635+
body: |
15636+
{
15637+
"results": [
15638+
{
15639+
"vulns": [
15640+
{
15641+
"id": "CVE-2023-53154",
15642+
"modified": "2026-03-14T12:23:16.581554Z"
15643+
},
15644+
{
15645+
"id": "CVE-2024-31755",
15646+
"modified": "2026-03-14T12:30:30.932017Z"
15647+
},
15648+
{
15649+
"id": "CVE-2025-57052",
15650+
"modified": "2026-03-23T05:11:28.908372Z"
15651+
}
15652+
]
15653+
}
15654+
]
15655+
}
15656+
headers:
15657+
Content-Length:
15658+
- "220"
15659+
Content-Type:
15660+
- application/json
15661+
status: 200 OK
15662+
code: 200
15663+
duration: 0s

internal/scalibrplugin/__snapshots__/resolve_test.snap

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ javascript/packagelockjson
3030
javascript/pnpmlock
3131
javascript/yarnlock
3232
license/depsdev
33+
misc/brew-source
3334
os/apk
3435
os/dpkg
36+
os/homebrew
3537
osv/osvscannerjson
3638
php/composerlock
3739
python/pdmlock
@@ -65,8 +67,10 @@ baseimage
6567
go/binary
6668
java/archive
6769
javascript/nodemodules
70+
misc/brew-source
6871
os/apk
6972
os/dpkg
73+
os/homebrew
7074
python/wheelegg
7175
rust/cargoauditable
7276
vex/os-duplicate/apk
@@ -102,9 +106,11 @@ baseimage
102106
go/binary
103107
java/archive
104108
javascript/nodemodules
109+
misc/brew-source
105110
os/apk
106111
os/dpkg
107112
python/wheelegg
113+
os/homebrew
108114
rust/cargoauditable
109115
vex/os-duplicate/apk
110116
vex/os-duplicate/dpkg

pkg/osvscanner/__snapshots__/osvscanner_test.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"package": {
1313
"name": "",
1414
"version": "",
15-
"ecosystem": "",
15+
"ecosystem": "GIT",
1616
"commit": "33dffa3909a67e1b5d22647128ab7eb6e53fd0c7"
1717
},
1818
"groups": [

0 commit comments

Comments
 (0)