-
Notifications
You must be signed in to change notification settings - Fork 34
Expand file tree
/
Copy pathacceptance.bats
More file actions
31 lines (25 loc) · 847 Bytes
/
acceptance.bats
File metadata and controls
31 lines (25 loc) · 847 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/usr/bin/env bats
@test "Not fail when testing a JavaScript SBOM" {
run ./parlay ecosystems enrich testing/sbom.cyclonedx.json
[ "$status" -eq 0 ]
}
@test "Not fail when testing a JavaScript CycloneDX 1.5 SBOM" {
run ./parlay ecosystems enrich testing/sbom.cyclonedx-1.5.json
[ "$status" -eq 0 ]
}
@test "Not fail when testing an SBOM on stdin" {
run bash -c "cat testing/sbom.cyclonedx.json | ./parlay ecosystems enrich -"
[ "$status" -eq 0 ]
}
@test "Not fail when testing a Java SBOM" {
run ./parlay ecosystems enrich testing/sbom2.cyclonedx.json
[ "$status" -eq 0 ]
}
@test "Not fail when testing a CycloneDX XML SBOM" {
run ./parlay ecosystems enrich testing/sbom.cyclonedx.xml
[ "$status" -eq 0 ]
}
@test "Fail when testing a non-existent file" {
run ./parlay ecosystems enrich not-here
[ "$status" -eq 1 ]
}