Files
tmux-themepack/test/version_test.go
Jim Myhrberg 6e2e24e0f2 feat(test): Add unit tests for all themes
Use Tmux itself by spinning up a temporary test server, load the theme,
and use "show-options" to pull out and validate relevant options that
are set by the theme.
2019-12-09 22:56:37 +00:00

26 lines
364 B
Go

package test
import (
"bytes"
"testing"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)
func TestTmuxVersion(t *testing.T) {
tmuxSetup()
defer tmuxTearDown()
if tmuxVersion != "" {
out, err := tm.Exec("-V")
require.NoError(t, err)
assert.Equal(
t,
"tmux "+tmuxVersion,
string(bytes.TrimSpace(out)),
)
}
}