-
Notifications
You must be signed in to change notification settings - Fork 155
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use Plugin Framework bridge to bring in new resources (#2557)
Start serving some resources off Plugin Framework Add acceptance test for PF based resources Use PlanState for diff strategy with provider Bring in newer pu/pu so the test harness framework support Pulumi yaml. Skip EditDirs in TestAccWebserver to workaround pulumi/pulumi#12859 --------- Co-authored-by: Ramon Quitales <[email protected]>
- Loading branch information
Showing
474 changed files
with
229,544 additions
and
11,541 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
// Copyright 2016-2023, Pulumi Corporation. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
//go:build nodejs || all | ||
// +build nodejs all | ||
|
||
package examples | ||
|
||
// NOTE about build tags: CI does not understand yaml-specific tags yet, but splits builds per language to run on | ||
// separate runners. This file piggy-backs on the nodejs tag so yaml tests will run on the same runner as node tests. | ||
|
||
import ( | ||
"os" | ||
"path/filepath" | ||
"testing" | ||
|
||
"github.com/pulumi/pulumi/pkg/v3/testing/integration" | ||
) | ||
|
||
// This test is not a proper examlpe but a test of the new capability to deploy Plugin Framework and SDKv2 based | ||
// resources alongside each other in the same provider. | ||
func TestAccPluginFramework(t *testing.T) { | ||
test := getYamlBaseOptions(t). | ||
With(integration.ProgramTestOptions{ | ||
Dir: filepath.Join(getCwd(t), "plugin-framework"), | ||
}) | ||
|
||
integration.ProgramTest(t, &test) | ||
} | ||
|
||
func getYamlBaseOptions(t *testing.T) integration.ProgramTestOptions { | ||
config := map[string]string{} | ||
_, usingProfiles := os.LookupEnv("AWS_PROFILE") | ||
if !usingProfiles { | ||
envRegion := getEnvRegion(t) | ||
config = map[string]string{ | ||
"aws:region": envRegion, | ||
} | ||
} | ||
// Do not use baseOptions here for now as those disable refresh checking. Be extra conservative. | ||
return integration.ProgramTestOptions{ | ||
Config: config, | ||
} | ||
} |
Oops, something went wrong.