Samuel Degueldre
6daa2d01b7
[IMP] web, *: use MutationObserver to neutralize image src in tests
...
*: mail, mrp
Previously, to prevent images and iframes from making GET requests in
tests, we would listen for the DOMNodeInserted event. This event is
deprecated and should not be used. Additionally, we weren't listening
for attiribute changes for performance reasons, which would result in
some GET requests still being made when an src attribute was changed.
This commit changes the mechanism that is used to do this from mutation
events to a MutationObserver which is not deprecated, and now also
listens for attribute modifications as MutationObservers can be
configured to only listen for changes to certain attributes, greatly
alleviating the performance impact of listening for those.
This mechanism has also been enabled globally by doing it once in the
test setup code, instead of requiring one to call a specific helper, as
we never want to make real requests during tests.
Some tests have been adapted to this new behaviour.
closes odoo/odoo#85216
Related: odoo/enterprise#24665
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com >
2022-02-23 15:07:59 +00:00
..
2022-02-23 13:58:08 +00:00
2022-02-21 13:13:56 +00:00
2022-02-14 10:44:50 +00:00
2022-01-05 11:36:06 +00:00
2022-02-08 11:07:54 +00:00
2022-02-18 18:13:37 +00:00
2022-02-08 11:07:54 +00:00
2021-12-08 16:28:53 +00:00
2022-01-28 14:10:01 +00:00
2021-11-08 09:25:47 +00:00
2021-11-23 11:12:14 +00:00
2022-01-28 14:10:01 +00:00
2022-02-21 17:01:02 +00:00
2021-11-26 09:44:58 +00:00
2022-02-14 10:44:50 +00:00
2022-02-21 17:01:02 +00:00
2021-11-22 14:48:04 +00:00
2022-02-21 17:01:02 +00:00
2022-02-07 14:18:00 +00:00
2022-02-07 14:17:59 +00:00
2022-02-14 10:44:50 +00:00
2022-02-15 09:26:54 +00:00
2022-02-18 14:29:20 +00:00
2022-02-21 17:01:02 +00:00
2021-12-14 12:39:54 +00:00
2022-02-21 17:01:02 +00:00
2021-12-07 13:48:53 +00:00
2022-02-12 08:55:18 +00:00
2022-02-10 07:46:13 +00:00
2022-02-18 13:26:49 +00:00
2021-12-16 09:00:19 +00:00
2022-02-12 08:55:18 +00:00
2022-02-08 14:54:02 +00:00
2022-02-21 17:01:02 +00:00
2022-02-14 10:44:50 +00:00
2022-01-28 14:10:01 +00:00
2021-12-15 00:10:51 +00:00
2021-12-14 12:39:54 +00:00
2022-02-14 10:44:50 +00:00
2021-12-02 12:12:01 +01:00
2022-02-02 11:46:52 +00:00
2021-12-08 09:35:03 +00:00
2022-02-23 12:59:52 +00:00
2021-12-16 17:33:47 +00:00
2022-02-01 15:32:26 +00:00
2021-12-24 14:57:02 +00:00
2022-02-21 08:41:30 +00:00
2021-12-16 17:33:47 +00:00
2022-02-12 08:55:18 +00:00
2022-02-14 10:44:50 +00:00
2022-02-21 13:13:52 +00:00
2022-02-12 08:55:18 +00:00
2022-02-14 10:44:50 +00:00
2022-02-17 16:41:56 +00:00
2022-02-12 08:55:18 +00:00
2022-02-14 10:44:50 +00:00
2021-11-22 14:48:04 +00:00
2022-02-14 07:58:56 +00:00
2022-02-23 13:57:55 +00:00
2022-02-17 19:32:40 +00:00
2022-02-22 09:41:54 +00:00
2022-02-18 12:29:00 +00:00
2022-01-20 16:08:22 +00:00
2022-02-22 11:59:16 +00:00
2022-02-15 16:51:11 +00:00
2021-12-14 19:13:18 +00:00
2021-12-09 16:14:43 +00:00
2021-12-07 13:48:53 +00:00
2022-02-22 12:53:00 +00:00
2021-12-25 02:26:44 +00:00
2022-02-17 10:08:53 +00:00
2021-12-15 12:07:26 +00:00
2022-02-18 12:29:00 +00:00
2022-01-03 18:11:19 +00:00
2022-02-14 10:44:50 +00:00
2022-02-02 18:14:54 +00:00
2022-02-14 19:25:02 +00:00
2022-02-08 12:05:54 +00:00
2022-02-21 17:01:02 +00:00
2022-02-21 17:01:02 +00:00
2022-02-16 16:57:20 +00:00
2022-02-21 17:01:02 +00:00
2021-11-25 00:31:17 +00:00
2021-12-08 11:17:22 +00:00
2022-02-20 20:39:50 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 12:17:06 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 17:01:02 +00:00
2022-02-12 08:55:18 +00:00
2022-01-25 17:21:04 +00:00
2022-02-12 08:55:18 +00:00
2022-01-27 21:50:25 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2021-12-18 21:00:49 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-17 09:06:57 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 16:07:50 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-17 16:41:51 +00:00
2022-01-27 21:50:25 +00:00
2021-12-17 21:59:10 +00:00
2022-01-11 13:34:56 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-01-27 21:50:25 +00:00
2021-12-14 14:47:25 +00:00
2022-02-08 14:53:55 +00:00
2022-02-21 07:49:49 +00:00
2022-02-21 12:17:06 +00:00
2022-02-22 15:19:58 +00:00
2022-01-14 14:49:57 +00:00
2022-02-12 08:55:18 +00:00
2022-01-28 14:10:01 +00:00
2022-01-28 14:10:01 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-01-12 10:17:47 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 12:17:06 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 12:17:06 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-23 12:08:57 +00:00
2021-12-22 00:12:52 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 12:17:06 +00:00
2022-01-27 21:50:25 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 11:24:10 +00:00
2022-02-14 10:44:50 +00:00
2022-02-23 15:07:59 +00:00
2022-02-12 08:55:18 +00:00
2021-12-21 09:49:38 +00:00
2022-02-14 10:44:50 +00:00
2021-12-14 19:13:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-22 12:53:00 +00:00
2021-12-07 13:48:53 +00:00
2022-01-06 11:45:23 +00:00
2022-02-22 12:53:00 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-23 15:07:59 +00:00
2022-01-19 16:03:53 +00:00
2021-12-07 16:20:05 +00:00
2022-01-11 15:24:11 +00:00
2022-02-16 11:30:29 +00:00
2021-12-07 16:20:05 +00:00
2021-12-07 16:20:06 +00:00
2021-12-07 16:20:06 +00:00
2022-02-18 13:26:49 +00:00
2022-02-14 10:44:50 +00:00
2022-02-23 09:06:53 +00:00
2022-02-18 09:49:20 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 17:01:02 +00:00
2022-02-16 09:40:11 +00:00
2022-02-12 08:55:18 +00:00
2022-02-11 11:40:23 +00:00
2022-02-21 17:01:02 +00:00
2022-02-16 09:40:11 +00:00
2022-02-14 10:44:50 +00:00
2022-02-11 11:40:23 +00:00
2022-02-15 16:51:24 +00:00
2022-02-02 19:50:49 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 17:01:02 +00:00
2022-02-22 19:47:53 +00:00
2022-02-22 19:47:54 +00:00
2022-02-14 10:44:50 +00:00
2022-02-14 10:44:50 +00:00
2022-02-14 22:31:02 +00:00
2022-02-14 10:44:50 +00:00
2022-01-27 21:50:25 +00:00
2022-02-14 10:44:50 +00:00
2022-02-22 15:19:42 +00:00
2022-02-15 11:23:52 +00:00
2022-02-14 10:44:50 +00:00
2022-02-18 10:46:53 +00:00
2022-02-18 09:49:20 +00:00
2022-02-11 11:40:12 +00:00
2022-02-14 10:44:50 +00:00
2022-02-14 10:44:50 +00:00
2022-02-21 17:01:02 +00:00
2022-02-14 10:44:50 +00:00
2022-01-19 16:52:23 +00:00
2022-02-22 19:47:52 +00:00
2022-01-04 17:03:10 +00:00
2021-12-14 12:39:54 +00:00
2022-01-04 17:03:10 +00:00
2022-01-04 17:03:10 +00:00
2022-02-11 11:40:07 +00:00
2022-02-21 17:01:02 +00:00
2022-01-10 14:49:52 +00:00
2021-11-24 16:33:01 +00:00
2022-02-02 09:03:44 +00:00
2022-02-21 17:01:02 +00:00
2022-02-23 11:00:42 +00:00
2022-02-12 08:55:18 +00:00
2022-02-01 14:37:37 +00:00
2022-02-21 17:01:02 +00:00
2022-02-14 22:31:03 +00:00
2022-02-22 17:11:01 +00:00
2022-02-04 10:23:43 +00:00
2021-12-02 12:12:03 +01:00
2022-02-21 17:01:02 +00:00
2021-12-02 12:12:03 +01:00
2022-02-14 10:44:50 +00:00
2022-02-17 17:37:51 +00:00
2022-02-17 17:37:51 +00:00
2022-02-17 10:08:43 +00:00
2021-11-23 11:12:14 +00:00
2022-02-14 10:44:50 +00:00
2022-01-14 17:29:35 +00:00
2022-02-21 17:01:02 +00:00
2021-11-08 07:59:42 +00:00
2022-02-17 10:08:43 +00:00
2021-11-29 14:55:35 +00:00
2022-02-01 14:37:54 +00:00
2022-02-18 13:26:49 +00:00
2022-02-18 13:26:49 +00:00
2022-02-22 17:11:09 +00:00
2022-02-21 17:01:02 +00:00
2021-12-07 16:20:06 +00:00
2022-02-14 10:44:50 +00:00
2022-02-21 16:08:01 +00:00
2022-02-22 18:29:31 +00:00
2022-01-19 16:52:23 +00:00
2022-02-23 12:59:52 +00:00
2022-02-02 18:14:54 +00:00
2022-02-23 12:59:52 +00:00
2022-02-10 13:30:51 +00:00
2022-02-02 18:14:54 +00:00
2022-01-20 15:11:50 +00:00
2022-02-17 17:37:51 +00:00
2022-01-17 16:56:01 +00:00
2022-02-18 14:28:53 +00:00
2022-02-21 12:16:57 +00:00
2022-01-17 06:42:47 +00:00
2022-02-12 08:55:18 +00:00
2022-02-23 13:58:12 +00:00
2022-02-22 12:53:00 +00:00
2022-02-23 15:07:59 +00:00
2022-02-23 09:06:58 +00:00
2022-02-15 09:26:54 +00:00
2022-02-21 17:01:02 +00:00
2022-02-23 12:59:52 +00:00
2022-02-23 12:59:52 +00:00
2022-02-22 12:53:00 +00:00
2022-02-14 10:44:50 +00:00
2022-02-23 10:02:04 +00:00
2022-02-12 08:55:18 +00:00
2022-02-22 15:19:23 +00:00
2021-12-07 13:48:53 +00:00
2022-02-21 08:41:33 +00:00
2022-02-14 10:44:50 +00:00
2022-02-08 14:53:37 +00:00
2022-02-14 10:44:50 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 08:41:33 +00:00
2022-02-17 17:37:41 +00:00
2021-12-07 13:48:53 +00:00
2022-02-17 17:37:40 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 10:28:15 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-08 14:53:37 +00:00
2022-02-12 08:55:18 +00:00
2022-02-18 13:26:49 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-12 08:55:18 +00:00
2022-02-15 09:26:54 +00:00
2022-02-08 14:53:39 +00:00
2022-02-08 14:53:39 +00:00
2022-01-22 11:51:42 +00:00
2022-02-21 08:41:33 +00:00
2022-02-21 08:41:30 +00:00
2022-02-21 08:41:30 +00:00
2022-02-21 08:41:30 +00:00
2022-02-21 08:41:33 +00:00
2022-02-12 08:55:18 +00:00
2022-02-21 08:41:30 +00:00
2022-02-21 08:41:30 +00:00
2022-02-22 15:19:27 +00:00
2022-02-21 08:41:33 +00:00
2021-12-23 15:30:23 +01:00
2022-02-21 08:41:30 +00:00
2022-02-22 19:47:53 +00:00
2021-12-07 13:48:53 +00:00
2022-02-21 12:16:57 +00:00
2022-02-12 08:55:18 +00:00