Skip to content

Commit

Permalink
Adding the capability to pass in a container image list to an Antithe…
Browse files Browse the repository at this point in the history
…sis test
  • Loading branch information
youhanaNaseim committed Jan 16, 2024
1 parent 96a568c commit d038fba
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 2 deletions.
2 changes: 2 additions & 0 deletions __tests__/main.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ describe('successful_action', () => {
return 'password'
case 'github_token':
return 'github_token'
case 'images':
return 'container1=sha1;container2=sha2;container3=sha3'
default:
return ''
}
Expand Down
4 changes: 4 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ inputs:
description: 'The Github token to be used to post back status updates'
required: true
default: ''
images:
description: 'The containers & digests that Antithesis tests will run on. If not specified the values will be inferred from the test.'
required: false
default: ''

# Define your outputs here.
outputs:
Expand Down
5 changes: 4 additions & 1 deletion dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,18 @@ export async function run(): Promise<void> {

core.info(`Callback Url: ${call_back_url}`)

// Read images informaiton
const images = core.getInput('images')

// Build the request body
const github_token = core.getInput('github_token')

const body = {
params: {
'antithesis.integrations.type': 'github',
'antithesis.integrations.call_back_url': call_back_url,
'antithesis.integrations.token': github_token
'antithesis.integrations.token': github_token,
'antithesis.images': images
}
}

Expand Down

0 comments on commit d038fba

Please sign in to comment.