Files
dagu/conformance/spec061_python_script/python_script_test.go
Arky 0fbd524c51 Add Python action conformance (#2720)
Cover the public contract with focused conformance checks.
2026-09-06 13:25:53 +09:00

32 lines
743 B
Go

// Copyright (C) 2026 Yota Hamada
// SPDX-License-Identifier: GPL-3.0-or-later
package spec061_python_script_test
import (
"testing"
"github.com/dagucloud/dagu/v2/conformance/harness"
)
// Validation checks the remote reference without provisioning its runtime.
func TestPythonScriptConfig(t *testing.T) {
t.Parallel()
t.Run("versioned action", func(t *testing.T) {
t.Parallel()
dagu := harness.NewRunner(t)
dagu.Run("validate", "configured.yaml").ExpectExitCode(0)
})
t.Run("missing version", func(t *testing.T) {
t.Parallel()
dagu := harness.NewRunner(t)
result := dagu.Run("validate", "no_version_suffix.yaml")
result.ExpectNonZeroExitCode()
result.ExpectStderrContains(`unknown action "python-script"`)
})
}