INNER CODE UNIT · Go
TestDataSource_Query_NullElementValue
hashicorp/terraform-provider-external · internal/provider/data_source_test.go:225
func TestDataSource_Query_NullElementValue(t *testing.T) {
programPath, err := buildDataSourceTestProgram()
if err != nil {
t.Fatal(err)
return
}
resource.UnitTest(t, resource.TestCase{
ProtoV5ProviderFactories: protoV5ProviderFactories(),
Steps: []resource.TestStep{
{
Config: fmt.Sprintf(`
data "external" "test" {
program = [%q]
query = {
# Program will return exit status 1 if the "fail" key is present.
fail = null