Skip to content

Commit

Permalink
Add tests to urlx, corx, cmdx
Browse files Browse the repository at this point in the history
Signed-off-by: aeneasr <aeneas.rekkas@serlo.org>
  • Loading branch information
aeneasr committed Oct 22, 2018
1 parent 5651b21 commit e4b2eef
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 0 deletions.
10 changes: 10 additions & 0 deletions cmdx/env_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package cmdx

import (
"github.com/stretchr/testify/assert"
"testing"
)

func TestEnvVarExamplesHelpMessage(t *testing.T) {
assert.NotEmpty(t, EnvVarExamplesHelpMessage(""))
}
9 changes: 9 additions & 0 deletions corsx/corsx_test.go
Original file line number Diff line number Diff line change
@@ -1 +1,10 @@
package corsx

import (
"github.com/stretchr/testify/assert"
"testing"
)

func TestHelpMessage(t *testing.T) {
assert.NotEmpty(t, HelpMessage())
}
10 changes: 10 additions & 0 deletions urlx/join_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package urlx

import (
"github.com/stretchr/testify/assert"
"testing"
)

func TestJoin(t *testing.T) {
assert.EqualValues(t, "http://foo/bar/baz/bar", MustJoin("http://foo", "bar/", "/baz", "bar"))
}

0 comments on commit e4b2eef

Please sign in to comment.