Skip to content

Commit

Permalink
CI: Build with and without cc side-by-side and no build cache
Browse files Browse the repository at this point in the history
  • Loading branch information
ParaskP7 committed Feb 4, 2025
1 parent 6b44cdd commit 0a756b4
Showing 1 changed file with 18 additions and 80 deletions.
98 changes: 18 additions & 80 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,92 +1,30 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildkite/pipeline-schema/main/schema.json
---

# Nodes with values to reuse in the pipeline.
common_params:
# Common plugin settings to use with the `plugins` key.
- &test_collector_common_params
files: "WooCommerce/build/buildkite-test-analytics/*.xml"
format: "junit"

agents:
queue: "android"

steps:
- label: Gradle Wrapper Validation
command: validate_gradle_wrapper
agents:
queue: linter

# Wait for Gradle Wrapper to be validated before running any other jobs
- wait

########################################
- group: "πŸ•΅οΈ Linters"
steps:

- label: "☒️ Danger - PR Check"
command: danger
key: danger
if: "build.pull_request.id != null"
retry:
manual:
permit_on_passed: true
agents:
queue: "linter"

- label: "detekt"
command: ./gradlew detektAll
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/detekt/detekt.html"

- label: "lint"
command: .buildkite/commands/lint.sh
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/lint-results*.*"

- label: "Dependency Tree Diff"
command: comment_with_dependency_diff 'woocommerce' 'vanillaReleaseRuntimeClasspath'
if: build.pull_request.id != null
plugins: [$CI_TOOLKIT]
artifact_paths:
- "**/build/reports/diff/*"

########################################
- group: "πŸ›  Prototype Builds"
steps:
- label: "πŸ›  Assemble with CC [No Build Cache]"
command: |
echo "--- :rubygems: Setting up Gems"
install_gems
- label: "πŸ›  Prototype Build: Mobile App"
command: ".buildkite/commands/prototype-build.sh WooCommerce"
if: build.pull_request.id != null
plugins: [$CI_TOOLKIT]
echo "--- :closed_lock_with_key: Installing Secrets"
bundle exec fastlane run configure_apply
- label: "πŸ›  Prototype Build: Wear App"
command: ".buildkite/commands/prototype-build.sh WooCommerce-Wear"
if: build.pull_request.id != null
plugins: [$CI_TOOLKIT]
echo "--- πŸ›  Build with CC [No Build Cache]"
./gradlew assembleJalapenoDebug --no-build-cache
plugins: [ $CI_TOOLKIT ]

########################################
- group: "πŸ”¬ Tests"
steps:
- label: "πŸ›  Assemble without CC [No Build Cache]"
command: |
echo "--- :rubygems: Setting up Gems"
install_gems
- label: "Unit tests"
command: .buildkite/commands/run-unit-tests.sh
plugins:
- $CI_TOOLKIT
- $TEST_COLLECTOR :
<<: *test_collector_common_params
api-token-env-name: "BUILDKITE_ANALYTICS_TOKEN_UNIT_TESTS"
artifact_paths:
- "**/build/test-results/merged-test-results.xml"
echo "--- :closed_lock_with_key: Installing Secrets"
bundle exec fastlane run configure_apply
- label: "Instrumented tests"
command: .buildkite/commands/run-instrumented-tests.sh
plugins:
- $CI_TOOLKIT
- $TEST_COLLECTOR :
<<: *test_collector_common_params
api-token-env-name: "BUILDKITE_ANALYTICS_TOKEN_INSTRUMENTED_TESTS"
artifact_paths:
- "**/build/instrumented-tests/**/*"
echo "--- πŸ›  Build without CC [No Build Cache]"
./gradlew assembleJalapenoDebug --no-build-cache --no-configuration-cache
plugins: [ $CI_TOOLKIT ]

0 comments on commit 0a756b4

Please sign in to comment.