Skip to content

Commit

Permalink
fix: fix test
Browse files Browse the repository at this point in the history
Signed-off-by: zongzhe <[email protected]>
  • Loading branch information
zong-zhe committed Oct 14, 2024
1 parent 10558bf commit eb0e155
Show file tree
Hide file tree
Showing 12 changed files with 2 additions and 64 deletions.
7 changes: 0 additions & 7 deletions pkg/client/test_data/test_vendor/dep1/kcl.mod

This file was deleted.

5 changes: 0 additions & 5 deletions pkg/client/test_data/test_vendor/dep1/kcl.mod.lock

This file was deleted.

1 change: 0 additions & 1 deletion pkg/client/test_data/test_vendor/dep1/main.k

This file was deleted.

7 changes: 0 additions & 7 deletions pkg/client/test_data/test_vendor/dep2/kcl.mod

This file was deleted.

5 changes: 0 additions & 5 deletions pkg/client/test_data/test_vendor/dep2/kcl.mod.lock

This file was deleted.

1 change: 0 additions & 1 deletion pkg/client/test_data/test_vendor/dep2/main.k

This file was deleted.

9 changes: 0 additions & 9 deletions pkg/client/test_data/test_vendor/pkg/kcl.mod

This file was deleted.

13 changes: 0 additions & 13 deletions pkg/client/test_data/test_vendor/pkg/kcl.mod.lock

This file was deleted.

13 changes: 0 additions & 13 deletions pkg/client/test_data/test_vendor/pkg/kcl.mod.lock.expect

This file was deleted.

1 change: 0 additions & 1 deletion pkg/client/test_data/test_vendor/pkg/main.k

This file was deleted.

2 changes: 1 addition & 1 deletion pkg/client/vendor.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func (c *KpmClient) VendorDeps(kclPkg *pkg.KclPkg) error {
}

func (c *KpmClient) vendorDeps(kclPkg *pkg.KclPkg, vendorPath string) error {
if ok, err := features.Enabled(features.SupportMVS); err != nil && ok {
if ok, err := features.Enabled(features.SupportMVS); err == nil && ok {
// Select all the vendored dependencies
// and fill the vendored dependencies into kclPkg.Dependencies.Deps
err := c.selectVendoredDeps(kclPkg, vendorPath, kclPkg.Dependencies.Deps)
Expand Down
2 changes: 1 addition & 1 deletion pkg/client/vendor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func testVendorDeps(t *testing.T) {
func testVendorWithMVS(t *testing.T) {
features.Enable(features.SupportMVS)
defer features.Disable(features.SupportMVS)
testDir := getTestDir("test_vendor")
testDir := getTestDir("test_vendor_mvs")
pkgPath := filepath.Join(testDir, "pkg")
kPkg, err := pkg.LoadKclPkgWithOpts(
pkg.WithPath(pkgPath),
Expand Down

0 comments on commit eb0e155

Please sign in to comment.