Skip to content

Commit

Permalink
Remove deprecated args
Browse files Browse the repository at this point in the history
  • Loading branch information
ffried committed Sep 17, 2023
1 parent 862cc7a commit 46af455
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 72 deletions.
62 changes: 0 additions & 62 deletions .github/workflows/tests.yml
Expand Up @@ -784,65 +784,3 @@ jobs:
printf "::error::Executed command did not match expectations!\nExecuted: ${ACTUAL_COMMAND}\nExpected: ${EXPECTED_COMMAND}\n"
exit 1
fi
test-dry-run-deprecated-args:
name: Dry Run Deprecated Args
runs-on: ubuntu-latest
env:
INPUT_PROJECT: TestProject.xcodeproj
INPUT_SCHEME: TestScheme
steps:
- if: ${{ github.event_name == 'pull_request' && env.RUNNER_DEBUG != 1 }}
run: echo 'RUNNER_DEBUG=1' >> "${GITHUB_ENV}"
- if: ${{ github.event_name == 'pull_request' }}
run: test "${RUNNER_DEBUG}" == "1"
- if: ${{ github.event_name == 'push' }}
env:
DEBUG_ENABLED: ${{ secrets.ACTIONS_STEP_DEBUG }}
run: test "${DEBUG_ENABLED}" == 'true'
- uses: actions/checkout@v4
- name: Generate action code
if: ${{ github.event_name == 'pull_request' }}
uses: ./.github/actions/generate-action-code
- uses: sersoft-gmbh/xcodebuild-action@main
if: ${{ github.event_name == 'push' }}
id: xcodebuild-main
with:
project: ${{ env.INPUT_PROJECT }}
scheme: ${{ env.INPUT_SCHEME }}
use-xcpretty: true
dry-run: true
- uses: './'
if: ${{ github.event_name == 'pull_request' }}
id: xcodebuild-local
with:
project: ${{ env.INPUT_PROJECT }}
scheme: ${{ env.INPUT_SCHEME }}
use-xcpretty: true
dry-run: true
- id: xcodebuild
env:
EVENT_NAME: ${{ github.event_name }}
BRANCH_UNPROCESSED_COMMAND: ${{ steps.xcodebuild-main.outputs.unprocessed-command }}
BRANCH_EXECUTED_COMMAND: ${{ steps.xcodebuild-main.outputs.executed-command }}
LOCAL_UNPROCESSED_COMMAND: ${{ steps.xcodebuild-local.outputs.unprocessed-command }}
LOCAL_EXECUTED_COMMAND: ${{ steps.xcodebuild-local.outputs.executed-command }}
run: |
if [ "${EVENT_NAME}" == 'push' ]; then
echo "unprocessed-command=${BRANCH_UNPROCESSED_COMMAND}" >> "${GITHUB_OUTPUT}"
echo "executed-command=${BRANCH_EXECUTED_COMMAND}" >> "${GITHUB_OUTPUT}"
else
echo "unprocessed-command=${LOCAL_UNPROCESSED_COMMAND}" >> "${GITHUB_OUTPUT}"
echo "executed-command=${LOCAL_EXECUTED_COMMAND}" >> "${GITHUB_OUTPUT}"
fi
- name: Check executed command
env:
UNPROCESSED_COMMAND: ${{ steps.xcodebuild.outputs.unprocessed-command }}
EXECUTED_COMMAND: ${{ steps.xcodebuild.outputs.executed-command }}
run: |
EXPECTED_COMMAND="xcodebuild -project ${INPUT_PROJECT} -scheme ${INPUT_SCHEME} test | xcpretty --color"
ACTUAL_COMMAND="${UNPROCESSED_COMMAND}"
if [ "${EXPECTED_COMMAND}" != "${ACTUAL_COMMAND}" ]; then
printf "::error::Executed command did not match expectations!\nExecuted: ${ACTUAL_COMMAND}\nExpected: ${EXPECTED_COMMAND}\n"
exit 1
fi
5 changes: 0 additions & 5 deletions dist/index.js
Expand Up @@ -238,11 +238,6 @@ async function main() {
const action = core.getInput('action', { required: true });
xcodebuildArgs.push(...action.split(' ').map(v => { return { name: v }; }));
let outputFormatter = core.getInput('output-formatter');
if (!outputFormatter && core.getBooleanInput('use-xcpretty')) {
outputFormatter = 'xcpretty';
if (core.getBooleanInput('xcpretty-colored-output'))
outputFormatter += ' --color';
}
const dryRun = core.isDebug() && core.getInput('dry-run') == 'true';
// We allow other platforms for dry-runs since this speeds up tests (more parallel builds).
if (!dryRun && process.platform !== 'darwin')
Expand Down
5 changes: 0 additions & 5 deletions src/main.ts
Expand Up @@ -242,11 +242,6 @@ async function main() {
xcodebuildArgs.push(...action.split(' ').map(v => { return { name: v }; }));

let outputFormatter = core.getInput('output-formatter');
if (!outputFormatter && core.getBooleanInput('use-xcpretty')) {
outputFormatter = 'xcpretty';
if (core.getBooleanInput('xcpretty-colored-output'))
outputFormatter += ' --color';
}

const dryRun = core.isDebug() && core.getInput('dry-run') == 'true';

Expand Down

0 comments on commit 46af455

Please sign in to comment.