Go test run configuration template in Goland

Spotted this on terraform-provider-kubectl

Turns out you can create a template for go configuration which will add some Env vars and other settings. Very useful if you have multiple test which you want to debug /run which have some env var prerequisites.

 1<component name="ProjectRunConfigurationManager">
 2  <configuration default="true" type="GoTestRunConfiguration" factoryName="Go Test">
 3    <module name="terraform-provider-kubectl" />
 4    <working_directory value="$PROJECT_DIR$" />
 5    <envs>
 6      <env name="TF_ACC" value="1" />
 7      <env name="KUBECONFIG" value="$PROJECT_DIR$/scripts/kubeconfig.yaml" />
 8    </envs>
 9    <kind value="DIRECTORY" />
10    <package value="github.com/gavinbunney/terraform-provider-kubectl" />
11    <directory value="$PROJECT_DIR$" />
12    <filePath value="$PROJECT_DIR$" />
13    <framework value="gotest" />
14    <method v="2" />
15  </configuration>
16</component>

Copyright

Comments