Skip to content
This repository was archived by the owner on Sep 9, 2020. It is now read-only.

Commit fbbac80

Browse files
committed
test(status): tableOutput show override constraint
Add integration test for tableOutput show override constraints.
1 parent 5b574d5 commit fbbac80

File tree

8 files changed

+75
-1
lines changed

8 files changed

+75
-1
lines changed

cmd/dep/status.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ func (out *tableOutput) BasicLine(bs *BasicStatus) {
9696
constraint = bs.Constraint.String()
9797
}
9898
if bs.hasOverride {
99-
constraint += "(override)"
99+
constraint += " (override)"
100100
}
101101
fmt.Fprintf(out.w,
102102
"%s\t%s\t%s\t%s\t%s\t%d\t\n",

cmd/dep/testdata/harness_tests/status/override_constraint/final/Gopkg.lock

Lines changed: 21 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[[override]]
2+
name = "github.com/sdboyer/deptest"
3+
version = "=0.8.1"

cmd/dep/testdata/harness_tests/status/override_constraint/initial/Gopkg.lock

Lines changed: 21 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[[override]]
2+
name = "github.com/sdboyer/deptest"
3+
version = "=0.8.1"
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
// Copyright 2016 The Go Authors. All rights reserved.
2+
// Use of this source code is governed by a BSD-style
3+
// license that can be found in the LICENSE file.
4+
5+
package main
6+
7+
import (
8+
_ "github.com/sdboyer/deptestdos"
9+
)
10+
11+
func main() {
12+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
PROJECT CONSTRAINT VERSION REVISION LATEST PKGS USED
2+
github.com/sdboyer/deptest * (override) v0.8.1 3f4c3be ff2948a 1
3+
github.com/sdboyer/deptestdos * v2.0.0 5c60720 5c60720 1
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"commands": [
3+
["ensure"],
4+
["status"]
5+
],
6+
"error-expected": "",
7+
"vendor-final": [
8+
"github.com/sdboyer/deptest",
9+
"github.com/sdboyer/deptestdos"
10+
]
11+
}

0 commit comments

Comments
 (0)