Skip to content
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

Add a step to the node CI test to confirm built scripts are included in the change #374

Merged
merged 12 commits into from
Sep 21, 2021

Conversation

jblz
Copy link
Contributor

@jblz jblz commented Sep 12, 2021

Description

After CI runs npm run build, flag the branch a failure if any uncommitted changes are detected.

Motivation and Context

Currently, there's no enforcement that built JS files are included when the source changes (or if build tooling alters the build). This seeks to provide some protection that build files are kept up to date with those changes.

How Has This Been Tested?

See the commit history & screen shots below.

Screenshots (if appropriate):

Screen Shot 2021-09-12 at 2 13 04 PM
Fail when files are missing in the build dir after build
Screen Shot 2021-09-12 at 2 16 40 PM
Fail when changes to src are not present in build
Screen Shot 2021-09-12 at 2 18 50 PM
Success when no uncommitted changes are present

Types of changes

Dev Tooling

@jblz jblz requested a review from a team as a code owner September 12, 2021 18:28
@GaryJones
Copy link
Contributor

The screenshots indicate that it's trying to protect against two cases, but the error message only points towards one?

echo "$REPOSTATUS";
exit 1;
else
echo The repo file system is clean.;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While true, it isn't indicative of what was actually being checked - that built files are present or not. Right now, those unfamiliar may not be able to join the dots between whether the file system is clean (is that good or bad?) and the real potential problem.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added a clarification message regarding this.

@GaryJones GaryJones merged commit bd8cdd1 into develop Sep 21, 2021
@GaryJones GaryJones deleted the add-js-build-test branch September 21, 2021 19:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants