terraform/helper/resource
Jake Champlin f24087ee54
core: Add ImportStateIdPrefix field for testing
Adds the `ImportStateIdPrefix` field for import acceptance tests. There are (albeit fairly rare) import cases where a resource needs to be imported with a combination of the resource's ID and a known string prefix. This allows the developer to specify the known prefix, and omit the `ImportStateId` field.

```
$ make test TEST=./helper/resource TESTARGS="-run=TestTest_importStateIdPrefix"
==> Checking that code complies with gofmt requirements...
==> Checking AWS provider for unchecked errors...
==> NOTE: at this time we only look for uncheck errors in the AWS package
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/03/30 18:08:36 Generated command/internal_plugin_list.go
go test -i ./helper/resource || exit 1
echo ./helper/resource | \
                xargs -t -n4 go test -run=TestTest_importStateIdPrefix -timeout=60s -parallel=4
go test -run=TestTest_importStateIdPrefix -timeout=60s -parallel=4 ./helper/resource
ok      github.com/hashicorp/terraform/helper/resource  0.025s
```
2017-03-30 18:11:10 -04:00
..
error.go helper/resource: Add retries to err message 2017-01-20 11:09:04 -08:00
id.go Fix resource.UniqueId to be properly ordered 2016-11-15 21:58:23 -05:00
id_test.go Fix resource.UniqueId to be properly ordered 2016-11-15 21:58:23 -05:00
map.go ResourceDiff => InstanceDiff 2014-09-17 16:33:24 -07:00
map_test.go helper/resource: automatically validate resources 2014-07-08 10:17:36 -07:00
resource.go ResourceDiff => InstanceDiff 2014-09-17 16:33:24 -07:00
state.go helper/resource: Allow unknown pending states (#13099) 2017-03-28 22:38:42 +03:00
state_test.go helper/resource: Allow unknown pending states (#13099) 2017-03-28 22:38:42 +03:00
testing.go core: Add ImportStateIdPrefix field for testing 2017-03-30 18:11:10 -04:00
testing_config.go testing: Add option to run only a plan on a TestStep configuration 2017-03-22 15:38:21 -05:00
testing_import_state.go core: Add ImportStateIdPrefix field for testing 2017-03-30 18:11:10 -04:00
testing_import_state_test.go core: Add ImportStateIdPrefix field for testing 2017-03-30 18:11:10 -04:00
testing_test.go testing: Add option to run only a plan on a TestStep configuration 2017-03-22 15:38:21 -05:00
wait.go Another race in resource.Retry 2016-07-29 18:35:54 -04:00
wait_test.go Timing out is not success 2016-06-30 18:07:56 -07:00