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

Exercise 11.18 Unsuccessful Deployment Test #13

Merged
merged 1 commit into from
Feb 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ module.exports = {
"no-trailing-spaces": "error",
"object-curly-spacing": ["error", "always"],
"arrow-spacing": ["error", { before: true, after: true }],
"no-console": 0,
"no-console": "error",
"react/prop-types": 0,
},
};
2 changes: 1 addition & 1 deletion .github/workflows/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:

- name: Notify about unsuccessful deployment
uses: rjstone/discord-webhook-notify@v1
if: failure()
if: ${{ failure() }}
with:
severity: error
text: Build failed
Expand Down
6 changes: 5 additions & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,15 @@
app.use(express.static("dist"));

app.listen(PORT, () => {
console.log(`server started on port ${PORT}`);

Check failure on line 10 in app.js

View workflow job for this annotation

GitHub Actions / build_and_test_app

Unexpected console statement
});

app.get("/version", (_req, res) => {
res.send("17"); // Ex 11.18 successful-deployment-branch
res.send("18"); // Ex 11.18 unsuccessful-deployment-branch test

console.log(

Check failure on line 16 in app.js

View workflow job for this annotation

GitHub Actions / build_and_test_app

Unexpected console statement
"This console log statement will fail the lintingm and hence resulting in unsuccessful deployment"
);
});

app.get("/health", (_req, res) => {
Expand Down
Loading