Skip to content

Releases: tenzir/test

Improved Debug Output

27 Jan 08:53
5a33fc7

Choose a tag to compare

This release improves the debugging experience by making the --debug flag automatically enable verbose output, so you see all test results when diagnosing failures.

🔧 Changes

Debug mode implies verbose output

The --debug flag (or TENZIR_TEST_DEBUG=1 environment variable) now automatically enables verbose output. When debugging test failures, you now see all test results (pass/skip/fail) instead of only failures, making it easier to diagnose issues. This provides more context without requiring users to pass both --debug and --verbose flags separately.

By @mavam and @claude in #9.

Multi-Word Command Fix

23 Jan 17:25
8e0b470

Choose a tag to compare

This release fixes an issue with diff tests failing when using multi-word Tenzir commands.

🐞 Bug fixes

Tuple unpacking in diff runner for multi-word commands

Fixed an error that occurred when running diff tests with multi-word Tenzir commands like uvx tenzir.

By @mavam and @claude in #8.

Automatic Binary Detection

23 Jan 13:51
1868156

Choose a tag to compare

This release introduces automatic binary detection with a clear precedence order: environment variables take priority, followed by PATH lookup, with uvx as fallback. Environment variables now support multi-part commands for full control over binary invocation. The --tenzir-binary and --tenzir-node-binary CLI flags have been removed in favor of environment variables.

💥 Breaking changes

Auto-detect Tenzir binary with uvx fallback

Binary detection now follows a consistent precedence order: environment variable TENZIR_BINARY takes priority, followed by a PATH lookup, with uvx as the final fallback. The same logic applies to TENZIR_NODE_BINARY. Environment variables now support multi-part commands like TENZIR_BINARY="uvx tenzir", giving you full control over how binaries are invoked. The --tenzir-binary and --tenzir-node-binary CLI flags have been removed in favor of environment variables, which provide more flexibility and clarity.

By @mavam and @claude in #7.

Verbose Output Control

23 Jan 09:19
87f9a3b

Choose a tag to compare

This release adds the --verbose flag for controlling test output verbosity. By default, only failures are shown, reducing noise in large test suites while still providing all details when needed.

🚀 Features

Verbose output flag for test results

The --verbose (or -v) flag makes per-test output opt-in, allowing you to reduce noise in large test suites. By default, quiet mode displays only failures and a compact summary.

Behavior with different flags:

  • Quiet mode (default): Hides passing and skipped tests, shows only failures and a tree summary when run with --summary
  • Verbose mode (--verbose / -v): Shows all test results as they complete, including passing and skipped tests, along with the tree summary if enabled
  • Passthrough mode (--passthrough): Automatically enables verbose output to preserve output ordering

This change gives you fine-grained control over test output verbosity, making it easier to focus on what matters when running large test suites.

By @mavam and @claude in #6.

Inline Test Inputs

15 Jan 14:50
1543a38

Choose a tag to compare

This release introduces inline test inputs for better test organization in deeply nested hierarchies. Tests can now place input data directly alongside test files, and you can create local inputs/ directories at any level with automatic shadowing semantics.

🚀 Features

Inline test inputs and local inputs directories

The test harness now supports inline test inputs for better test organization in deeply nested test hierarchies.

Tests can now place input data directly alongside test files using the .input extension. The harness automatically sets the TENZIR_INPUT environment variable pointing to <test>.input when the file exists. This makes test dependencies immediately visible without requiring you to navigate to a distant inputs/ directory.

Additionally, you can now create inputs/ directories at any level in the test hierarchy. The harness walks up from each test and uses the nearest inputs/ directory for TENZIR_INPUTS, with shadowing semantics where nearer directories take precedence. This lets you organize shared test data close to the tests that use it.

The resolution hierarchy for TENZIR_INPUTS is:

  1. inputs: override in test frontmatter or test.yaml (highest priority)
  2. Nearest inputs/ directory walking up from the test
  3. Package-level tests/inputs/ directory
  4. Project-level inputs/ directory (fallback)

All existing tests continue to work with the global inputs/ directory.

By @mavam and @claude.

Tenzir Test v0.13.1

08 Dec 15:56
e0e5658

Choose a tag to compare

This release fixes path handling in the diff runner to strip root path prefixes from output, making paths relative and consistent with other test runners.

🐞 Bug fixes

Strip root paths from diff_runner output

The DiffRunner now strips the ROOT path prefix from output to make paths relative, consistent with run_simple_test behavior.

By @tobim and @claude in #5.

Tenzir Test v0.13.0

03 Dec 19:52
408fe38

Choose a tag to compare

This release adds --package-dirs support and improves startup diagnostics.

🚀 Features

Library mode and extra packages

Explicit package loading for tests: use --package-dirs (repeatable, accepts comma-separated lists) to point the harness at package directories. The same flag is passed to the Tenzir binaries, and it merges with any package-dirs: declared in directory test.yaml files. Entries are normalized and de-duplicated, then exported via TENZIR_PACKAGE_DIRS for fixtures.

The test configuration uses the same spelling: add

package-dirs:
  - ../shared-packages
  - /opt/tenzir/packages/foo

to a directory test.yaml when you want those packages available for the tests below it.

Example: uvx tenzir-test --package-dirs example-library example-library loads both foo and bar packages so their operators can cross-import. The example-library test.yaml files demonstrate the config-based approach if you prefer not to pass the --package-dirs flag.

By @codex and @mavam in #4.

🔧 Changes

Improve diagnostics when Tenzir Node fails to start

The node fixture now reports the exit code and stderr output when tenzir-node fails to start, making it easier to diagnose startup failures. Previously, the error message provided no context about why the node failed to produce an endpoint.

By @Alainx277 and @claude in #2.

Tenzir Test 0.12.0

05 Nov 12:31
318553f

Choose a tag to compare

Minor release with improved NO_COLOR handling.

🚀 Features

Add configurable color output control

We switched library consumers to plain output by default and added full NO_COLOR support, keeping ANSI colors only where they enhance the interactive experience.

When you import tenzir_test.run directly, the harness now emits unstyled text by default—perfect for log parsers, CI systems, and automation scripts that expect machine-readable output. If you need colors back, call run.set_color_mode(run.ColorMode.ALWAYS) to force ANSI sequences on, or use run.ColorMode.AUTO to let the harness detect terminal capabilities.

The tenzir-test CLI continues to auto-detect your terminal and renders colors when you run tests interactively. Redirect stdout to a file or pipe, and it automatically switches to plain mode. Set NO_COLOR=1 in your environment, and every output—failure trees, diff hunks, retry banners—strips its color codes.

All palette logic now lives in a single helper that colorizes checkmarks, crosses, diff lines, and progress indicators consistently. This unification means run.print_diff(...) respects your color mode choice everywhere, whether you invoke it from the CLI or from library code.

We added pytest coverage for all three modes—CLI with colors, library without colors, and NO_COLOR=1 forcing plain output—so future changes won't break the contract.

By @codex and @mavam.

Tenzir Test v0.11.0

04 Nov 07:17
d9714fc

Choose a tag to compare

Expose tenzir-test as a reusable Python library.

🚀 Features

Expose tenzir-test as a library

The test framework now exposes its harness as a reusable Python library, returning structured execution results instead of exiting the process. Callers can import the new execute helper and receive an ExecutionResult with project summaries, exit codes, and failure details for downstream automation.

Example:

from pathlib import Path

from tenzir_test import ExecutionResult, execute

result: ExecutionResult = execute(tests=[Path("tests/pipeline.tql")])
if result.exit_code:
    raise SystemExit(result.exit_code)
for project in result.project_results:
    print(project.selection.root, project.summary.total)

By @mavam and @codex.

Release v0.10.0

27 Oct 15:00
08576c9

Choose a tag to compare

Highlights

  • Capture stderr for failing runs and display it inline for both Tenzir and shell runners.
  • Add regression tests covering the new failure presentation and sample stderr output in the example project.