Skip to content

Test Styles Build Chain, Long Way

Wesley B edited this page Jul 29, 2022 · 1 revision

Steps

Confirm similar or identical build output for project(s) on default branch versus the branch to test.

When checking out branches:
If branch has change to dependency or version of dependency, then run npm ci.

When running commands:
This document assumes the current working directory to be /libs/core-styles.

  1. Clean out any previous testing you may have done with these steps.
    git rm -rf dist-for-compare
  2. Confirm CSS on default branch builds.

    Follow default branch's instructions to build.

  3. Copy build output to new directory, and stage the change with Git.
    rm -rf dist-for-compare
    cp -r dist dist-for-compare
    git add dist-for-compare
  4. Confirm CSS on new branch builds.

    Follow new branch's instructions to build.

  5. Replace that copied old build output with new build output (do not stage).
    rm -rf dist-for-compare
    cp -r dist dist-for-compare
  6. Compare the build outputs via git status.
    git status
  7. Confirm you see only relevant staged changes.
    • (via git status) You should see "Changes to be committed" for dist-for-compare/.
    • (via git status) You may see "Changes not staged for commit" for dist-for-compare/.


    The test instructions that led you to this document will clarify whether you should see "Changes not staged for commit" (represents build output change) and if so, what should have changed.

Clone this wiki locally