-
Notifications
You must be signed in to change notification settings - Fork 26
chore(CI): add backwards compatability tests for nightly #790
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
5d59af1
chore(CI): add backwards compatability tests for nightly
josecorella 3f35e48
format
josecorella 37cb15d
Update .github/workflows/dafny_interop_library_go_tests.yml
josecorella ce2dda4
Merge branch 'mainline' into jocorell/change-nightly-tasks
robin-aws d114b4e
fix
josecorella 6ae4cd6
f
josecorella File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,108 @@ | ||
| # This workflow performs tests in Go with nightly latest versions for mpl or esdk. | ||
| name: Library Go Backwards Interop Tests | ||
|
|
||
| on: | ||
| workflow_call: | ||
| inputs: | ||
| mpl-dafny: | ||
| description: "The Dafny version to compile the MPL with (4.2.0, dafny-nightly, etc..)" | ||
| required: true | ||
| type: string | ||
| mpl-commit: | ||
| description: "The MPL commit to use" | ||
| required: false | ||
| default: "main" | ||
| type: string | ||
| esdk-dafny: | ||
| description: "The Dafny version to compile the DBESDK with (4.2.0, dafny-nightly, etc..)" | ||
| required: true | ||
| type: string | ||
|
|
||
| jobs: | ||
| testGo: | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| library: [TestVectors] | ||
| go-version: ["1.23"] | ||
| os: [ | ||
| # Sed script doesn't work properly on windows | ||
| # windows-latest, | ||
| ubuntu-22.04, | ||
| # TODO: Re-enable macOS after https://t.corp.amazon.com/P205755286 | ||
| # macos-13, | ||
| ] | ||
| runs-on: ${{ matrix.os }} | ||
| permissions: | ||
| id-token: write | ||
| contents: read | ||
| steps: | ||
| - name: Support longpaths on Git checkout | ||
| run: | | ||
| git config --global core.longpaths true | ||
| - uses: actions/checkout@v3 | ||
| - name: Init Submodules | ||
| shell: bash | ||
| run: | | ||
| git submodule update --init libraries | ||
| git submodule update --init --recursive mpl | ||
|
|
||
| - name: Configure AWS Credentials | ||
| uses: aws-actions/configure-aws-credentials@v2 | ||
| with: | ||
| aws-region: us-west-2 | ||
| role-to-assume: arn:aws:iam::370957321024:role/GitHub-CI-Public-ESDK-Dafny-Role-us-west-2 | ||
| role-session-name: GoTests | ||
|
|
||
| - name: Setup MPL Dafny | ||
| uses: ./mpl/.github/actions/setup_dafny | ||
| with: | ||
| dafny-version: ${{ inputs.mpl-dafny }} | ||
|
|
||
| - name: Update MPL submodule | ||
| working-directory: mpl | ||
| run: | | ||
| git fetch | ||
| git checkout ${{inputs.mpl-commit}} | ||
| git pull | ||
| git submodule update --init --recursive | ||
| git rev-parse HEAD | ||
|
|
||
| - name: Install Smithy-Dafny codegen dependencies | ||
| uses: ./.github/actions/install_smithy_dafny_codegen_dependencies | ||
|
|
||
| - name: Install Go | ||
| uses: actions/setup-go@v5 | ||
| with: | ||
| go-version: ${{ matrix.go-version }} | ||
|
|
||
| - name: Install Go imports | ||
| run: | | ||
| go install golang.org/x/tools/cmd/goimports@latest | ||
|
|
||
| - name: Compile MPL with Dafny ${{inputs.mpl-dafny}} | ||
| shell: bash | ||
| working-directory: mpl/TestVectorsAwsCryptographicMaterialProviders | ||
| run: | | ||
| # This works because `node` is installed by default on GHA runners | ||
| CORES=$(node -e 'console.log(os.cpus().length)') | ||
| make transpile_go CORES=$CORES | ||
|
|
||
| - name: Setup ESDK Dafny | ||
| uses: ./mpl/.github/actions/setup_dafny | ||
| with: | ||
| dafny-version: ${{ inputs.esdk-dafny}} | ||
|
|
||
| - name: Build ESDK implementation | ||
| shell: bash | ||
| working-directory: ./${{ matrix.library }} | ||
| run: | | ||
| # This works because `node` is installed by default on GHA runners | ||
| CORES=$(node -e 'console.log(os.cpus().length)') | ||
| make transpile_go CORES=$CORES | ||
|
|
||
| - name: Test Go | ||
| working-directory: ${{ matrix.library }} | ||
| shell: bash | ||
| run: | | ||
| make test_go |
This file contains hidden or 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 hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it make more sense to add this target to the Manual CI workflow instead? Or perhaps at least as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn't; at least for now. I don't see how adding it to manual gives you more insights than to just run this action individually