Skip to content

Commit d6d2a5d

Browse files
committed
workflow update
1 parent 0940d02 commit d6d2a5d

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/unit-test.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,10 @@ jobs:
4747
4848
- name: Run Unit Tests for Affected Plugins
4949
run: |
50-
for plugin in ${{ steps.changes.outputs.affected_plugins }}; do
51-
echo "Running tests for $plugin..."
52-
npm run test:unit --prefix ./packages/$plugin
53-
done
50+
# Only run tests for contentstack-audit if it's affected
51+
if [[ "$${{ steps.changes.outputs.affected_plugins }}" == *"contentstack-audit"* ]]; then
52+
echo "Running tests for contentstack-audit..."
53+
npm run test:unit --prefix ./packages/contentstack-audit
54+
else
55+
echo "contentstack-audit has not changed. Skipping tests."
56+
fi

0 commit comments

Comments
 (0)