Skip to content

Commit

Permalink
Skip tests
Browse files Browse the repository at this point in the history
  • Loading branch information
iwahbe committed Dec 9, 2024
1 parent f9311e6 commit 686794a
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 64 deletions.
10 changes: 0 additions & 10 deletions .ci-mgmt.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,7 @@ plugins:
- name: terraform
version: "1.0.16"
kind: converter

- name: aws
version: "4.2.0"
actions:
preTest:
- name: Ensure upstream
run: make upstream
- name: Setup local Keycloak
run: make -C upstream local
- name: Run provider tests
run: |
cd provider && go test -v -json -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt
pulumiConvert: 1
registryDocs: true
7 changes: 0 additions & 7 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -175,13 +175,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: v2.5.0
- name: Ensure upstream
run: make upstream
- name: Setup local Keycloak
run: make -C upstream local
- name: Run provider tests
run: |
cd provider && go test -v -json -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt
- name: Run tests
run: cd examples && go test -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4
strategy:
Expand Down
7 changes: 0 additions & 7 deletions .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: v2.5.0
- name: Ensure upstream
run: make upstream
- name: Setup local Keycloak
run: make -C upstream local
- name: Run provider tests
run: |
cd provider && go test -v -json -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt
- name: Run tests
run: cd examples && go test -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 .
strategy:
Expand Down
7 changes: 0 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,13 +122,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: v2.5.0
- name: Ensure upstream
run: make upstream
- name: Setup local Keycloak
run: make -C upstream local
- name: Run provider tests
run: |
cd provider && go test -v -json -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt
- name: Run tests
run: cd examples && go test -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 .
strategy:
Expand Down
7 changes: 0 additions & 7 deletions .github/workflows/run-acceptance-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -171,13 +171,6 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: v2.5.0
- name: Ensure upstream
run: make upstream
- name: Setup local Keycloak
run: make -C upstream local
- name: Run provider tests
run: |
cd provider && go test -v -json -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -parallel 4 . 2>&1 | tee /tmp/gotest.log | gotestfmt
- name: Run tests
if: matrix.testTarget == 'local'
run: cd examples && go test -count=1 -cover -timeout 2h -tags=${{ matrix.language }} -skip TestPulumiExamples -parallel 4 .
Expand Down
10 changes: 4 additions & 6 deletions examples/examples_dotnet_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
// 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 dotnet || all
// +build dotnet all

package examples
Expand All @@ -20,19 +21,16 @@ import (
"github.com/pulumi/pulumi/pkg/v3/testing/integration"
)

func getCSBaseOptions() integration.ProgramTestOptions {
base := getBaseOptions()
csharpBase := base.With(integration.ProgramTestOptions{
func getCSBaseOptions(t *testing.T) integration.ProgramTestOptions {
return getBaseOptions(t).With(integration.ProgramTestOptions{
Dependencies: []string{
"Pulumi.Keycloak",
},
})

return csharpBase
}

func TestAccRealmCsharp(t *testing.T) {
test := getCSBaseOptions().
test := getCSBaseOptions(t).
With(integration.ProgramTestOptions{
Dir: path.Join(getCwd(t), "realm", "csharp"),
})
Expand Down
10 changes: 4 additions & 6 deletions examples/examples_go_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
// 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 go || all
// +build go all

package examples
Expand All @@ -21,21 +22,18 @@ import (
)

func TestAccRealmGo(t *testing.T) {
test := getGoBaseOptions().
test := getGoBaseOptions(t).
With(integration.ProgramTestOptions{
Dir: filepath.Join(getCwd(t), "realm", "go"),
})

integration.ProgramTest(t, &test)
}

func getGoBaseOptions() integration.ProgramTestOptions {
base := getBaseOptions()
goBase := base.With(integration.ProgramTestOptions{
func getGoBaseOptions(t *testing.T) integration.ProgramTestOptions {
return getBaseOptions(t).With(integration.ProgramTestOptions{
Dependencies: []string{
"github.com/pulumi/pulumi-keycloak/sdk/v4",
},
})

return goBase
}
10 changes: 4 additions & 6 deletions examples/examples_nodejs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
// 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
Expand All @@ -20,19 +21,16 @@ import (
"github.com/pulumi/pulumi/pkg/v3/testing/integration"
)

func getJSBaseOptions() integration.ProgramTestOptions {
base := getBaseOptions()
baseJS := base.With(integration.ProgramTestOptions{
func getJSBaseOptions(t *testing.T) integration.ProgramTestOptions {
return getBaseOptions(t).With(integration.ProgramTestOptions{
Dependencies: []string{
"@pulumi/keycloak",
},
})

return baseJS
}

func TestAccRealmTs(t *testing.T) {
test := getJSBaseOptions().
test := getJSBaseOptions(t).
With(integration.ProgramTestOptions{
Dir: path.Join(getCwd(t), "realm", "ts"),
})
Expand Down
10 changes: 4 additions & 6 deletions examples/examples_py_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
// 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 python || all
// +build python all

package examples
Expand All @@ -21,19 +22,16 @@ import (
"github.com/pulumi/pulumi/pkg/v3/testing/integration"
)

func getPythonBaseOptions() integration.ProgramTestOptions {
base := getBaseOptions()
basePython := base.With(integration.ProgramTestOptions{
func getPythonBaseOptions(t *testing.T) integration.ProgramTestOptions {
return getBaseOptions(t).With(integration.ProgramTestOptions{
Dependencies: []string{
filepath.Join("..", "sdk", "python", "bin"),
},
})

return basePython
}

func TestAccRealmPython(t *testing.T) {
test := getPythonBaseOptions().
test := getPythonBaseOptions(t).
With(integration.ProgramTestOptions{
Dir: path.Join(getCwd(t), "realm", "python"),
})
Expand Down
3 changes: 2 additions & 1 deletion examples/examples_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ func getCwd(t *testing.T) string {
return cwd
}

func getBaseOptions() integration.ProgramTestOptions {
func getBaseOptions(t *testing.T) integration.ProgramTestOptions {
t.Skip("Skipping tests - this provider is not high enough usage to merit automated E2E testing in CI")
return integration.ProgramTestOptions{
ExpectRefreshChanges: true,
}
Expand Down
2 changes: 1 addition & 1 deletion upstream.sh
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ rebase() {
interactive_flag="--interactive"
fi
if ! git rebase --onto "${onto}" ${interactive_flag}; then
echo "Rebase failed. Please resolve the conflicts and run 'git rebase --continue' in the upstream directory."
echo "Rebase failed. Please resolve the conflicts and run 'git rebase --continue' in the upstream directory. Once the rebase is complete, run '${original_exec} check_in' to write to commits back to patches."
exit 1
fi
cd ..
Expand Down

0 comments on commit 686794a

Please sign in to comment.