@@ -727,3 +727,84 @@ data "google_compute_network" "default" {
727727}
728728` , context )
729729}
730+
731+ func TestAccNetappStoragePool_unifiedStoragePoolCreate (t * testing.T ) {
732+ t .Parallel ()
733+
734+ context := map [string ]interface {}{
735+ "network_name" : acctest .BootstrapSharedServiceNetworkingConnection (t , "gcnv-network-config-3" , acctest .ServiceNetworkWithParentService ("netapp.servicenetworking.goog" )),
736+ "random_suffix" : acctest .RandString (t , 10 ),
737+ }
738+
739+ acctest .VcrTest (t , resource.TestCase {
740+ PreCheck : func () { acctest .AccTestPreCheck (t ) },
741+ ProtoV5ProviderFactories : acctest .ProtoV5ProviderFactories (t ),
742+ Steps : []resource.TestStep {
743+ {
744+ Config : testAccNetappStoragePool_unifiedStoragePoolCreate (context ),
745+ },
746+ {
747+ ResourceName : "google_netapp_storage_pool.test_pool" ,
748+ ImportState : true ,
749+ ImportStateVerify : true ,
750+ ImportStateVerifyIgnore : []string {"location" , "name" , "labels" , "terraform_labels" },
751+ },
752+ {
753+ Config : testAccNetappStoragePool_unifiedStoragePoolCreate_update (context ),
754+ },
755+ {
756+ ResourceName : "google_netapp_storage_pool.test_pool" ,
757+ ImportState : true ,
758+ ImportStateVerify : true ,
759+ ImportStateVerifyIgnore : []string {"location" , "name" , "labels" , "terraform_labels" },
760+ },
761+ },
762+ })
763+ }
764+
765+ func testAccNetappStoragePool_unifiedStoragePoolCreate (context map [string ]interface {}) string {
766+ return acctest .Nprintf (`
767+
768+ data "google_compute_network" "default" {
769+ name = "%{network_name}"
770+ }
771+
772+ resource "google_netapp_storage_pool" "test_pool" {
773+ name = "tf-test-pool%{random_suffix}"
774+ location = "us-central1-a"
775+ service_level = "FLEX"
776+ type = "UNIFIED"
777+ capacity_gib = "2048"
778+ network = data.google_compute_network.default.id
779+ description = "this is a test description"
780+ labels = {
781+ key = "test"
782+ value = "pool"
783+ }
784+ }
785+ ` , context )
786+ }
787+
788+ func testAccNetappStoragePool_unifiedStoragePoolCreate_update (context map [string ]interface {}) string {
789+ return acctest .Nprintf (`
790+
791+ data "google_compute_network" "default" {
792+ name = "%{network_name}"
793+ }
794+
795+ resource "google_netapp_storage_pool" "test_pool" {
796+ name = "tf-test-pool%{random_suffix}"
797+ location = "us-central1-a"
798+ service_level = "FLEX"
799+ type = "UNIFIED"
800+ capacity_gib = "2048"
801+ network = data.google_compute_network.default.id
802+ description = "this is a test description"
803+ labels = {
804+ key = "test"
805+ value = "pool"
806+ }
807+ total_throughput_mibps = "200"
808+ }
809+ ` , context )
810+ }
0 commit comments