gitlab.com/sparetimecoders/build-tools@v0.1.0/pkg/testing.go (about)

     1  // +build !prod
     2  
     3  package pkg
     4  
     5  import (
     6  	"os"
     7  )
     8  
     9  func SetEnv(key, value string) func() {
    10  	_ = os.Setenv(key, value)
    11  	return func() { _ = os.Unsetenv(key) }
    12  }