Skip to content

[BUG] Unit tests run fine with go test, but fail when used with Ginkgo CLI #1621

Open
@HeavyWombat

Description

@HeavyWombat

Is there an existing issue for this?

  • I have searched the existing issues

Kubernetes Version

n/a

Shipwright Version

Starting with 977a065.

Current Behavior

Unit tests in cmd/image-processing, which are written for Ginkgo/Gomega do not run when executed with Ginkgo CLI.

Expected Behavior

Unit tests written for Ginkgo should run fine with the Ginkgo CLI as the driver.

Steps To Reproduce

  1. Clone repo
  2. Run go run github.com/onsi/ginkgo/v2/ginkgo run --coverprofile=unit.coverprofile --output-dir=build/coverage --randomize-all --trace ./cmd/image-processing

Fails with

  [FAILED] Unexpected error:
      <*fs.PathError | 0x140007dc0c0>:
      open : no such file or directory
      {
          Op: "open",
          Path: "",
          Err: <syscall.Errno>0x2,
      }
  occurred
  In [It] at: /path/github.ibm.com/coligo/source-to-image/src/build/cmd/image-processing/main_test.go:211 @ 06/12/24 21:25:06.745

  Full Stack Trace

Anything else?

No response

Metadata

Metadata

Assignees

Labels

kind/bugCategorizes issue or PR as related to a bug.

Type

No type

Projects

Status

No status

Relationships

None yet

Development

No branches or pull requests

Issue actions