Skip to content

Programmer #128

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 18 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix tests
  • Loading branch information
matteosuppo committed Oct 20, 2016
commit 2bcf6433e9cbfcd24717180448404e5eb44cfc6a
12 changes: 7 additions & 5 deletions programmer/programmer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,20 +36,22 @@ func TestSerial(t *testing.T) {

for _, test := range TestSerialData {
commandline := strings.Replace(test.Commandline, "~", home, -1)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here?!

err := programmer.Do(test.Port, commandline, test.Extra, logger)
err := programmer.Serial(test.Port, commandline, test.Extra, logger)
log.Println(err)
}
}

var TestNetworkData = []struct {
Name string
Port string
Board string
File string
Commandline string
Extra programmer.Extra
Auth programmer.Auth
}{
{
"yun", "",
``, programmer.Extra{Network: true}},
"yun", "", "", "",
``, programmer.Auth{}},
}

func TestNetwork(t *testing.T) {
Expand All @@ -60,7 +62,7 @@ func TestNetwork(t *testing.T) {

for _, test := range TestNetworkData {
commandline := strings.Replace(test.Commandline, "~", home, -1)
err := programmer.Do(test.Port, commandline, test.Extra, logger)
err := programmer.Network(test.Port, test.Board, test.File, commandline, test.Auth, logger)
log.Println(err)
}
}
Expand Down