# test.govlab/context/configuration/strings/ontology.strings.test.ts

> 24 lines of code and 0 definitions.

Tree: Codebase Testing
Language: typescript
Canonical: https://banes-lab.com/anatomy/testing#file-testing-test-govlab-context-configuration-strings-ontology-strings-test-ts
Source text: https://banes-lab.com/source/testing/test.govlab/context/configuration/strings/ontology.strings.test.ts.txt

Listed in [test.govlab/context/configuration/strings](https://banes-lab.com/api/source/testing/test.govlab/context/configuration/strings.md), after [test.govlab/context/configuration/strings/ontology.report.strings.test.ts](https://banes-lab.com/source/testing/test.govlab/context/configuration/strings/ontology.report.strings.test.ts.md) and before [test.govlab/context/configuration/strings/reason.strings.test.ts](https://banes-lab.com/source/testing/test.govlab/context/configuration/strings/reason.strings.test.ts.md).

## Contained in

- [test.govlab/context/configuration/strings](https://banes-lab.com/anatomy/testing/folder-testing-test-govlab-context-configuration-strings.md)

## Source

```typescript
import {
    collectionCycle,
    debugLine,
    duplicateCollection,
    duplicateRecordId,
    emptyRecordId,
    missingDependency,
    unbuiltCollection,
    unregisteredCollection,
} from "@govlab/context/configuration/strings/ontology.strings.ts";
import assert from "node:assert/strict";
import { test } from "vitest";

test("a debug line carries the package namespace ahead of the message", () => {
    assert.equal(debugLine("loaded"), "[govlab:context] loaded");
});

test("every collection message names the collection or the record it reports", () => {
    assert.ok(duplicateRecordId("lexicon", "a").includes('"a"'));
    assert.ok(emptyRecordId("lexicon").startsWith("lexicon:"));
    assert.ok(duplicateCollection("pag").includes('"pag"'));
    assert.ok(collectionCycle("pag").includes('"pag"'));
    assert.ok(unregisteredCollection("pag").includes('"pag"'));
    assert.ok(unbuiltCollection("pag").includes('"pag"'));
    assert.equal(missingDependency("layers", "lexicon"), "layers collection requires the lexicon collection");
});
```
