mirror of
https://github.com/norandom/OpenUltraSAST.git
synced 2026-11-13 09:48:18 +00:00
test(detection-core): validate end-to-end readiness paths
This commit is contained in:
+3
@@ -0,0 +1,3 @@
|
||||
def publish(request: object, store: object, policy: object) -> None:
|
||||
if policy.permits(request):
|
||||
store.publish(request)
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
def publish(request: object, store: object, allowed: bool) -> None:
|
||||
if allowed:
|
||||
store.publish(request)
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
def publish(request: object, store: object) -> None:
|
||||
store.publish(request)
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"schema_version": "detection-core-source-authority-v1",
|
||||
"repository": "obligation_repository",
|
||||
"producer_identity": "reference-fixture-author@v1",
|
||||
"reviewer_identity": "independent-reference-review@v1",
|
||||
"cases": [
|
||||
{
|
||||
"case_id": "obligation-positive",
|
||||
"path": "reference/obligation_positive.py",
|
||||
"content_digest": "e29307cd0ae6d1d817c19fd79bfa4d494d602fc5daf9aad4e6da9caa1ee31e29"
|
||||
},
|
||||
{
|
||||
"case_id": "obligation-negative",
|
||||
"path": "reference/obligation_negative.py",
|
||||
"content_digest": "223e1065ef30aa0cb1073125e2f845c1b2b5a498400ac34cdc5f78bb0621cd7a"
|
||||
},
|
||||
{
|
||||
"case_id": "obligation-missing",
|
||||
"path": "reference/obligation_missing.py",
|
||||
"content_digest": "c119b846e6797a9e1b6c96aff73426c1f53a46053ab074f88931e7d07383652c"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
def handle(value: str, effect: object, transform: object) -> None:
|
||||
effect.write(transform.apply(value))
|
||||
@@ -0,0 +1,2 @@
|
||||
def handle(value: str, effect: object) -> None:
|
||||
effect.write(value.strip())
|
||||
@@ -0,0 +1,2 @@
|
||||
def handle(value: str, effect: object) -> None:
|
||||
effect.write(value)
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"schema_version": "detection-core-source-authority-v1",
|
||||
"repository": "taint_repository",
|
||||
"producer_identity": "reference-fixture-author@v1",
|
||||
"reviewer_identity": "independent-reference-review@v1",
|
||||
"cases": [
|
||||
{
|
||||
"case_id": "flow-positive",
|
||||
"path": "reference/flow_positive.py",
|
||||
"content_digest": "ece3add1d60cf01527cb83746b20c3be1f9468c589677932830efbb6a5d67a48"
|
||||
},
|
||||
{
|
||||
"case_id": "flow-negative",
|
||||
"path": "reference/flow_negative.py",
|
||||
"content_digest": "2413778080ea6626b47dff8ee82a54f88902707a90e1f41c67a7380bc8784a5f"
|
||||
},
|
||||
{
|
||||
"case_id": "flow-missing",
|
||||
"path": "reference/flow_missing.py",
|
||||
"content_digest": "662b99c3c093b38de535ab21b17a1acfe10bb70911c8b83768844b607424c345"
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user