mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #15716 from overleaf/bg-eslint-console-log-in-web-tests
add console.log rule for tests in web eslintrc GitOrigin-RevId: 166135e379309870fa4fe2d1797cb4c93cf2d877
This commit is contained in:
parent
9ce9b2c937
commit
26db8ffa69
4 changed files with 5 additions and 5 deletions
|
@ -299,7 +299,9 @@
|
|||
"**/app/**/*.{js,cjs,mjs}", "app.js", "modules/*/*.js",
|
||||
// Frontend: Prefer debugConsole over bare console
|
||||
// Docs: https://manual.dev-overleaf.com/development/code/logging/#frontend
|
||||
"**/frontend/**/*.{js,jsx,ts,tsx}"
|
||||
"**/frontend/**/*.{js,jsx,ts,tsx}",
|
||||
// Tests
|
||||
"**/test/**/*.{js,cjs,mjs,jsx,ts,tsx}"
|
||||
],
|
||||
"excludedFiles": [
|
||||
// Allow console logs in scripts
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
/* eslint-disable no-console */
|
||||
// silence settings module
|
||||
console.log = function () {}
|
||||
const Settings = require('@overleaf/settings')
|
||||
|
|
|
@ -118,10 +118,8 @@ describe('ConvertArchivedState', function () {
|
|||
beforeEach(function (done) {
|
||||
exec(
|
||||
'CONNECT_DELAY=1 node scripts/convert_archived_state.js FIRST,SECOND',
|
||||
(error, stdout, stderr) => {
|
||||
error => {
|
||||
if (error) {
|
||||
console.log(stdout)
|
||||
console.error(stderr)
|
||||
return done(error)
|
||||
}
|
||||
done()
|
||||
|
|
|
@ -186,7 +186,6 @@ describe('SAMLIdentityManager', function () {
|
|||
error = e
|
||||
} finally {
|
||||
expect(error).to.exist
|
||||
console.log(error)
|
||||
expect(error.message).to.contain(
|
||||
'missing data when linking institution SSO'
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue