github.com/mhlo/force@v0.22.28-0.20150915022417-6d05ecfb0b47/logins_test.go (about)

     1  package main
     2  
     3  import (
     4  	"github.com/bmizerany/assert"
     5  	"github.com/mhlo/config"
     6  	"testing"
     7  )
     8  
     9  var TestConfig = config.NewConfig("force")
    10  
    11  // test that SetActiveLogin in turn sets the "current account"
    12  func TestSetActiveLogin(t *testing.T) {
    13  	SetActiveLogin("clint")
    14  	account, _ := TestConfig.Load("current", "account")
    15  	assert.Equal(t, account, "clint")
    16  }