ignore package translations in jest
refs LS-3017 flag=none test plan: - tests pass qa risk: low Change-Id: I8da0db910b0647405f27b04c1f9c143b35126f70 Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/286184 Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com> Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com> QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com> Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
This commit is contained in:
parent
51d6db63f4
commit
c8d8efe784
|
@ -255,7 +255,7 @@ module.exports = {
|
|||
}
|
||||
},
|
||||
{
|
||||
files: ['ui/**/*', 'spec/**/*', 'public/**/*'],
|
||||
files: ['ui/**/*', 'spec/**/*', 'public/**/*', 'jest/**/*'],
|
||||
rules: {
|
||||
// Turn off the "absolute-first" rule. Until we get rid of the `compiled/` and `jsx/`
|
||||
// stuff and use real realitive paths it will tell you to do the wrong thing
|
||||
|
|
|
@ -19,10 +19,22 @@
|
|||
import Enzyme from 'enzyme'
|
||||
import Adapter from 'enzyme-adapter-react-16'
|
||||
import {filterUselessConsoleMessages} from '@instructure/js-utils'
|
||||
import rceFormatMessage from '@instructure/canvas-rce/lib/format-message'
|
||||
import plannerFormatMessage from '@instructure/canvas-planner/lib/format-message'
|
||||
import {up as configureDateTime} from '../ui/boot/initializers/configureDateTime'
|
||||
|
||||
import {up as configureDateTimeMomentParser} from '../ui/boot/initializers/configureDateTimeMomentParser'
|
||||
|
||||
rceFormatMessage.setup({
|
||||
locale: 'en',
|
||||
missingTranslation: 'ignore'
|
||||
})
|
||||
|
||||
plannerFormatMessage.setup({
|
||||
locale: 'en',
|
||||
missingTranslation: 'ignore'
|
||||
})
|
||||
|
||||
/**
|
||||
* We want to ensure errors and warnings get appropriate eyes. If
|
||||
* you are seeing an exception from here, it probably means you
|
||||
|
@ -97,8 +109,15 @@ const ignoredWarnings = [
|
|||
/Exactly one focusable child is required/,
|
||||
/Please update the following components: %s/,
|
||||
/shared_brand_configs.* not called/,
|
||||
/Translation for .* is missing/,
|
||||
/value provided is not in a recognized RFC2822 or ISO format/
|
||||
/value provided is not in a recognized RFC2822 or ISO format/,
|
||||
// the following warnings were not appropriately failing tests upon console.warn
|
||||
// filtered from output, will need to be investigated within /ui/features/k5_*
|
||||
/Unmatched GET to \/api\/v1\/announcements/,
|
||||
/Unmatched GET to \/api\/v1\/users\/\d+\/calendar_events/,
|
||||
/Unmatched GET to \/api\/v1\/courses\/\d+\/assignment_groups/,
|
||||
/Unmatched GET to \/api\/v1\/courses\/\d+\/enrollments/,
|
||||
/Unmatched GET to \/api\/v1\/courses\/\d+\/assignment_groups/
|
||||
// end k5 console.warn investigation
|
||||
]
|
||||
global.console = {
|
||||
log: console.log,
|
||||
|
|
Loading…
Reference in New Issue