Skip to content
Beskid Platform specification

Beskid

Jump to a Beskid service

Beskid

Jump to a Beskid service

Testing

Spec standingStandard

Owner
Piotr Mikstacki
Submitter
Piotr Mikstacki

Defines the test item, discovery metadata, and skip rules for language-level tests. Harness execution is realized by tooling and corelib helpers.

test MyCase {
meta { timeout = 30; }
// statements
}
  • test Name { body } declares a test entry point; the identifier is followed directly by the test body block (no parameter list).
  • meta { key = expr; } sections attach metadata (timeouts, categories) parsed as TestMetaSection.
  • skip { key = expr; } sections mark conditional skip predicates.
  • Test bodies must contain only statements and meta/skip sections allowed by TestBodyItem.
  • Tests may appear in Test project kinds; placement in App/Lib projects should warn per manifest policy.
  • Attributes on tests follow the general attribute rules (E1508–E1510).
  • The test runner must invoke each discovered test entrypoint in isolation unless meta specifies shared fixtures (future).
  • Failed assertions must report as test failures without undefined behavior.
  • Skipped tests must not count as failures when skip predicates evaluate true.

Attribute and visibility issues use E15xx; test-specific codes may be added in the registry band reserved for tooling.

beskid test (tooling) must discover all test items in Test projects matching this syntax.

  • D-LM-TST-001 — First-class test item: Tests are module items, not attributes on functions only.
  • D-LM-TST-002 — meta/skip blocks: Structured sections replace ad hoc comment conventions.
  • D-LM-TST-003 — Test project kind: Discovery should scope to Test projects unless manifest policy allows otherwise.
  • D-LM-TST-004 — Corelib helpers are additive: Assertion helpers in corelib must not redefine language-level test syntax.

The language-level test harness, discovery, and assertions users rely on. Corelib testing helpers extend but do not redefine these semantics.