mirror of https://github.com/schollz/croc.git
fix tests
This commit is contained in:
parent
a96762b942
commit
2ac7d4f31f
|
@ -29,7 +29,7 @@ func TestCrocReadme(t *testing.T) {
|
|||
log.Debug("setting up sender")
|
||||
sender, err := New(Options{
|
||||
IsSender: true,
|
||||
SharedSecret: "test",
|
||||
SharedSecret: "8123-testingthecroc",
|
||||
Debug: true,
|
||||
RelayAddress: "localhost:8081",
|
||||
RelayPorts: []string{"8081"},
|
||||
|
@ -37,6 +37,8 @@ func TestCrocReadme(t *testing.T) {
|
|||
Stdout: false,
|
||||
NoPrompt: true,
|
||||
DisableLocal: true,
|
||||
Curve: "siec",
|
||||
Overwrite: true,
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
|
@ -45,13 +47,15 @@ func TestCrocReadme(t *testing.T) {
|
|||
log.Debug("setting up receiver")
|
||||
receiver, err := New(Options{
|
||||
IsSender: false,
|
||||
SharedSecret: "test",
|
||||
SharedSecret: "8123-testingthecroc",
|
||||
Debug: true,
|
||||
RelayAddress: "localhost:8081",
|
||||
RelayPassword: "pass123",
|
||||
Stdout: false,
|
||||
NoPrompt: true,
|
||||
DisableLocal: true,
|
||||
Curve: "siec",
|
||||
Overwrite: true,
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
|
@ -89,7 +93,7 @@ func TestCrocLocal(t *testing.T) {
|
|||
log.Debug("setting up sender")
|
||||
sender, err := New(Options{
|
||||
IsSender: true,
|
||||
SharedSecret: "test",
|
||||
SharedSecret: "8123-testingthecroc",
|
||||
Debug: true,
|
||||
RelayAddress: "localhost:8181",
|
||||
RelayPorts: []string{"8181", "8182"},
|
||||
|
@ -97,6 +101,8 @@ func TestCrocLocal(t *testing.T) {
|
|||
Stdout: true,
|
||||
NoPrompt: true,
|
||||
DisableLocal: false,
|
||||
Curve: "siec",
|
||||
Overwrite: true,
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
|
@ -106,13 +112,15 @@ func TestCrocLocal(t *testing.T) {
|
|||
log.Debug("setting up receiver")
|
||||
receiver, err := New(Options{
|
||||
IsSender: false,
|
||||
SharedSecret: "test",
|
||||
SharedSecret: "8123-testingthecroc",
|
||||
Debug: true,
|
||||
RelayAddress: "localhost:8181",
|
||||
RelayPassword: "pass123",
|
||||
Stdout: true,
|
||||
NoPrompt: true,
|
||||
DisableLocal: false,
|
||||
Curve: "siec",
|
||||
Overwrite: true,
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
|
@ -163,7 +171,7 @@ func TestCrocError(t *testing.T) {
|
|||
log.SetLevel("warn")
|
||||
sender, _ := New(Options{
|
||||
IsSender: true,
|
||||
SharedSecret: "test33",
|
||||
SharedSecret: "8123-testingthecroc2",
|
||||
Debug: true,
|
||||
RelayAddress: "doesntexistok.com:8381",
|
||||
RelayPorts: []string{"8381", "8382"},
|
||||
|
@ -171,6 +179,8 @@ func TestCrocError(t *testing.T) {
|
|||
Stdout: true,
|
||||
NoPrompt: true,
|
||||
DisableLocal: true,
|
||||
Curve: "siec",
|
||||
Overwrite: true,
|
||||
})
|
||||
err = sender.Send(TransferOptions{
|
||||
PathToFiles: []string{tmpfile.Name()},
|
||||
|
|
Loading…
Reference in New Issue