Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,30 @@ into `kubernetes/deployment.yaml`. The changed manifest is committed and
applied like any other change. `kubernetes/` is not part of the image, so
writing the digest does not change the image.

The Nu Html Checker in the manifest is version 26.10.12. Its digest is
compared with the latest release once a month, and at once when a security
notice concerns the checker or its image:

```
docker buildx imagetools inspect ghcr.io/validator/validator:latest
```

If the digest shown there differs from the one in `kubernetes/deployment.yaml`,
the checker is updated in one pull request:

1. Write the new digest into `kubernetes/deployment.yaml` and into
`test/fixtures/files/html/DPP-DAT-020/README.md`, and the new version into
both READMEs.
2. Record the answers of the new checker to the test vectors again, as that
README describes, and run the test suite. Every file in `valid/` must still
have no error and every file in `invalid/` at least one; if a new rule of
the checker moves a vector, the pull request says which and why.
3. Check the HTML views of the example passports with the new checker before
the manifest is applied.

The dpplint image does not change for this; the manifest is applied like any
other change.

## Tests

```
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ spec:
app: dpplint
containers:
- name: dpplint
image: oydeu/dpplint@sha256:30f7b99950874ba357455baf42e68ad96968db9f65246e73f559300904f07414
image: oydeu/dpplint@sha256:721ff836b23f36b8ed9541732d07f49e7ebeec988f46e20b2ef987ce99572e94
imagePullPolicy: IfNotPresent
ports:
- containerPort: 3000
Expand Down
4 changes: 3 additions & 1 deletion test/integration/validations_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@ def criterion(result, id) = result["criteria"].find { |c| c["id"] == id }
result = criterion(lint(reference), "DPP-CAR-002")
assert_equal "warning", result["result"]
assert_equal ["warning"], result["messages"].map { |m| m["severity"] }
assert_match(/GS1 prefix 952/, result["messages"].first["message"])
assert_match(/\AThe GTIN of the GS1 Digital Link carries the GS1 prefix 952,/, result["messages"].first["message"])
passport = reference.merge("uniqueProductIdentifier" => "https://dpp.example.org/01/00000095212340/21/000001")
assert_equal "warning", criterion(lint(passport), "DPP-CAR-002")["result"], "GTIN-8 with the GS1-8 prefix 952, padded to 14 digits"
end

test "GTIN with another prefix passes the product identifier scheme without a warning" do
Expand Down
Loading