Files
odoo_source/addons/mail/static/tests/models/qunit_test.js
T
tsm-odoo bc2bf646c9 [IMP] mail, *: remove createThreadViewComponent in tests.
*: sms, snailmail.

The createThreadViewComponent helper was used during tests to mount
a thread view component  and test it. However, this approach is not
very realistic and blocks some waiting PRs. In order to get closer
from the reality, let's mount a webClient so that the thread view
component can be mounted in its real environment.

task-2871066

closes odoo/odoo#94691

Related: odoo/enterprise#28954
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-06-29 17:11:30 +02:00

47 lines
1.3 KiB
JavaScript

/** @odoo-module **/
import { registerModel } from '@mail/model/model_core';
import { one } from '@mail/model/model_field';
registerModel({
name: 'QUnitTest',
identifyingFields: [], // singleton acceptable (only one test at a time)
fields: {
clockWatcher: one('ClockWatcher', {
inverse: 'qunitTestOwner',
isCausal: true,
}),
composer: one('Composer', {
isCausal: true,
}),
composerView: one('ComposerView', {
inverse: 'qunitTest',
isCausal: true,
}),
followerListMenuView: one('FollowerListMenuView', {
inverse: 'qunitTest',
isCausal: true,
}),
notificationListView: one('NotificationListView', {
inverse: 'qunitTestOwner',
isCausal: true,
}),
throttle1: one('Throttle', {
inverse: 'qunitTestOwner1',
isCausal: true,
}),
throttle2: one('Throttle', {
inverse: 'qunitTestOwner2',
isCausal: true,
}),
timer1: one('Timer', {
inverse: 'qunitTestOwner1',
isCausal: true,
}),
timer2: one('Timer', {
inverse: 'qunitTestOwner2',
isCausal: true,
}),
},
});