Skip to content

Commit

Permalink
Fix field name to match Dredd (#37)
Browse files Browse the repository at this point in the history
* Fix field name to match dredd

Fixes a bug introduced in 0.3.0

* Fix spelling
  • Loading branch information
IngmarStein authored and ddelnano committed Aug 25, 2017
1 parent 2d09c7c commit 87fd9cd
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
18 changes: 9 additions & 9 deletions cmd/goodman/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,17 @@ import (
)

var (
c chan os.Signal
cmds chan *exec.Cmd
runners []goodman.Runner
hookServerInitalPort = 61322
hooksServerCount int
c chan os.Signal
cmds chan *exec.Cmd
runners []goodman.Runner
hookServerInitialPort = 61322
hooksServerCount int
)

func main() {
cmds = make(chan *exec.Cmd, 50)
args := os.Args
hookPaths := args[1:len(args)]
hookPaths := args[1:]
c = make(chan os.Signal, 1)
signal.Notify(c, os.Interrupt, syscall.SIGTERM)
go func() {
Expand All @@ -39,7 +39,7 @@ func main() {
runners = append(runners, &goodman.DummyRunner{})
} else {
for _, path := range hookPaths {
cmd := exec.Command(path, fmt.Sprintf("-port=%d", hookServerInitalPort))
cmd := exec.Command(path, fmt.Sprintf("-port=%d", hookServerInitialPort))
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
fmt.Println("Sending to channel\n")
Expand All @@ -56,7 +56,7 @@ func main() {
}()
rpcService := reflect.TypeOf((*hooks.HooksRunner)(nil)).Elem().Name()
for retries := 5; retries > 0; retries-- {
runner, err := goodman.NewRunner(rpcService, hookServerInitalPort)
runner, err := goodman.NewRunner(rpcService, hookServerInitialPort)
if err == nil {
runners = append(runners, runner)
break
Expand All @@ -72,7 +72,7 @@ func main() {
}
panic(err.Error())
}
hookServerInitalPort++
hookServerInitialPort++
}
}
close(cmds)
Expand Down
2 changes: 1 addition & 1 deletion transaction/transaction.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ type Transaction struct {
StatusCode string `json:"statusCode,omitempty"`
Body string `json:"body,omitempty"`
Headers map[string]interface{} `json:"headers,omitempty"`
Schema *json.RawMessage `json:"schema,omitempty"`
Schema *json.RawMessage `json:"bodySchema,omitempty"`
} `json:"expected,omitempty"`
Real *struct {
Body string `json:"body"`
Expand Down

0 comments on commit 87fd9cd

Please sign in to comment.