diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 5cd92488763..7457c63742b 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -7,4 +7,3 @@ updates: time: '11:00' open-pull-requests-limit: 10 target-branch: "v7" - vendor: true diff --git a/.github/workflows/release-update-repos.yml b/.github/workflows/release-update-repos.yml index 26f58d8195b..f909849c021 100644 --- a/.github/workflows/release-update-repos.yml +++ b/.github/workflows/release-update-repos.yml @@ -1,9 +1,6 @@ name: "Release: Update Repositories" on: - push: - branches: "v*" - workflow_dispatch: inputs: build_version: diff --git a/.github/workflows/tests-integration-reusable.yml b/.github/workflows/tests-integration-reusable.yml index 05847e836f0..917fd5914bd 100644 --- a/.github/workflows/tests-integration-reusable.yml +++ b/.github/workflows/tests-integration-reusable.yml @@ -52,7 +52,7 @@ jobs: echo "version=$version" >> $GITHUB_OUTPUT - name: Checkout cf-deployment Min CAPI - if: ${{ inputs.capi-version != 'edge' }} + if: inputs.capi-version != 'edge' uses: actions/checkout@v3 with: repository: cloudfoundry/cf-deployment @@ -61,7 +61,7 @@ jobs: - name: Checkout cf-deployment uses: actions/checkout@v3 - if: ${{ inputs.capi-version == 'edge' }} + if: inputs.capi-version == 'edge' with: repository: cloudfoundry/cf-deployment path: cf-deployment @@ -134,7 +134,7 @@ jobs: credhub --version - name: Deploy edge CAPI with Isolation Segment and OIDC Provider - if: ${{ inputs.capi-version == 'edge' }} + if: inputs.capi-version == 'edge' env: CF_INT_CLIENT_SECRET: ${{ secrets.CLIENT_SECRET }} run: | @@ -161,7 +161,7 @@ jobs: bosh -d cf releases | grep capi - name: Deploy MIN CAPI with Isolation Segment and OIDC Provider - if: ${{ inputs.capi-version != 'edge' }} + if: inputs.capi-version != 'edge' run: | # TODO: Make this actually deploy min capi # Creates vars files @@ -217,7 +217,7 @@ jobs: check-latest: true - name: Run Integration Tests - if: ${{ !inputs.run-with-client-creds }} + if: !inputs.run-with-client-creds run: | ENV=$(cat metadata.json | jq -r '.name') eval "$(bbl print-env --metadata-file ./metadata.json)" @@ -244,7 +244,7 @@ jobs: make integration-tests-full-ci - name: Run Integration Tests with client credentials - if: ${{ inputs.run-with-client-creds }} + if: inputs.run-with-client-creds env: CF_INT_CLIENT_ID: 'potato-face' CF_INT_CLIENT_SECRET: ${{ secrets.CLIENT_SECRET }} diff --git a/.github/workflows/tests-integration.yml b/.github/workflows/tests-integration.yml index 9cbc407195b..a2d4882a498 100644 --- a/.github/workflows/tests-integration.yml +++ b/.github/workflows/tests-integration.yml @@ -11,7 +11,7 @@ on: jobs: run-integration-tests-cf-env-with-edge-capi: name: Integration tests with EDGE CAPI - if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} + if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' uses: ./.github/workflows/tests-integration-reusable.yml with: capi-version: edge @@ -22,7 +22,7 @@ jobs: run-integration-tests-cf-env-with-edge-capi-with-client-creds: name: EDGE CAPI and client creds - if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} + if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' uses: ./.github/workflows/tests-integration-reusable.yml with: capi-version: edge @@ -33,7 +33,7 @@ jobs: run-integration-tests-cf-env-with-min-capi: name: MIN CAPI - if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} + if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' uses: ./.github/workflows/tests-integration-reusable.yml with: capi-version: min @@ -44,7 +44,7 @@ jobs: #run-integration-windows: # name: Windows - # if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} + # if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' # uses: ./.github/workflows/tests-integration-reusable.yml # with: # capi-version: edge @@ -55,7 +55,7 @@ jobs: #run-integration-windows-client-credentials: # name: Windows with client credentials - # if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }} + # if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' # uses: ./.github/workflows/tests-integration-reusable.yml # with: # capi-version: edge diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index bcd768fece3..00000000000 --- a/.travis.yml +++ /dev/null @@ -1,14 +0,0 @@ -language: go -go: - - 1.13.x -go_import_path: code.cloudfoundry.org/cli -install: -- go get -u github.com/onsi/ginkgo/ginkgo -script: -- NODES=1 make units-full -branches: - only: - - master - - travis -os: - - linux diff --git a/integration/helpers/fake_data.go b/integration/helpers/fake_data.go index b3740864fd9..88e378a765e 100644 --- a/integration/helpers/fake_data.go +++ b/integration/helpers/fake_data.go @@ -1,16 +1,16 @@ package helpers import ( + "embed" "fmt" - "io/ioutil" - "net/http" - "os" - "path/filepath" - . "github.com/onsi/gomega" "github.com/onsi/gomega/ghttp" + "net/http" ) +//go:embed fixtures +var content embed.FS + // AddFiftyOneOrgs adds a mock handler to the given server which returns // 51 orgs on GET requests to /v3/organizations?order_by=name. It also // paginates, so page 2 can be requested with /v3/organizations?page=2&per_page=50. @@ -81,9 +81,7 @@ func AddEmptyPaginatedResponse(server *ghttp.Server, path string) { } func fixtureData(name string) []byte { - wd := os.Getenv("GOPATH") - fp := filepath.Join(wd, "src", "code.cloudfoundry.org", "cli", "integration", "helpers", "fixtures", name) - b, err := ioutil.ReadFile(fp) + b, err := content.ReadFile("fixtures/" + name) Expect(err).ToNot(HaveOccurred()) return b }