Commit graph

187 commits

Author SHA1 Message Date
Barret Rennie
cfd0ca6d9e Bug 1779950 - Keep FxMS test corpus up-to-date for make-schemas.py r=nalexander
The fxms schema job has been updated with a script that writes out the test
corpus for the test. This means we no longer need to keep these JSON files in
tree, since the test will automatically generate them.

Differential Revision: https://phabricator.services.mozilla.com/D151985
2022-07-21 00:47:46 +00:00
Barret Rennie
9637ace6bf Bug 1775187 - Refactor out common elements of FxMS schema r=Mardak
The following propertie have been refactored out into the top-level message
schema so that they don't have to be repeated in each template's schema:

- `frequency`
- `groups`
- `id`
- `priority`

A definition for the `trigger` property has been added to the common schemas as
`MessageTrigger` so that messages that require triggering can reference this
definition.

Each template schema now requires only its template (as a const value or enum)
and its content, as well as any additional top-level properties that are
message specific (e.g., `order` for `WhatsNewMessage`).

`id`, `content`, and `template` properties are required for all messages.
Individual template schemas do not need to mark `content` and `template` as
required since they are required by the top-level schema. Messages that
require triggering or targeting must define those properties.

Differential Revision: https://phabricator.services.mozilla.com/D150705
2022-07-21 00:47:45 +00:00
Barret Rennie
da9f5d6170 Bug 1779109 - Add a schema for protections_panel template r=Mardak
Differential Revision: https://phabricator.services.mozilla.com/D151560
2022-07-21 00:47:44 +00:00
Barret Rennie
dcd9fb02ee Bug 1775187 - Refactor out localizableText and localizedText from FxMS schemas r=nalexander,dmose
Several kinds of FxMS messages support a common pattern of taking either a
string or an object containing a string ID, allowing for both raw strings and
translated string IDs to be used in messages. This patch refactors that pattern
out into a common definition (localizedText and localizableText) in a common
schema which other schemas can then reference.

Our schema bundling script has been updated to bundle these definitions from
the common schema as top-level definitions (and subsequently rewrite the
references from FxMSCOmmon.schema.json to the generated schema) because Nimbus
and Experimenter only support a single schema file per feature.

To ensure compatability with Experimenter, all our in-tree messages have been
extracted into a test corpus that is validated with the Experimenter JSON
Schema validator. A future patch in this series will clean this up so we don't
need to have separate copies of messages in the tree.

We are now also validating all messages from the CFRMessageProvider with our
in-tree JSON Schema validator that Nimbus uses. The OnboardingMessageProvider
and PanelTestProvider tests have also been updated so that all three are using
the same testing infrastructure.

Differential Revision: https://phabricator.services.mozilla.com/D150704
2022-07-21 00:47:44 +00:00
Iulian Moraru
3c09fc13df Backed out 3 changesets (bug 1780074, bug 1780347) for causing multiple failures. CLOSED TREE
Backed out changeset ee4c4d34816c (bug 1780347)
Backed out changeset a13d3939b98a (bug 1780074)
Backed out changeset 3bc739f7de43 (bug 1780074)
2022-07-20 14:57:48 +03:00
Mark Banner
3ad13294d8 Bug 1780074 - Migrate newtab consumers to use ESM imports directly. r=daleharvey,application-update-reviewers,nalexander
Differential Revision: https://phabricator.services.mozilla.com/D152114
2022-07-20 10:36:52 +00:00
Nick Alexander
a67a0b63a4 Bug 1775128 - Add toast_notification message template for displaying (native) toast notifications. r=Mardak
Differential Revision: https://phabricator.services.mozilla.com/D150073
2022-07-20 02:58:42 +00:00
Punam Dahiya
22d80d654a Bug 1779654- Add SpecialMessageAction BLOCK_MESSAGE that allows to block message r=jprickett
To be used in about:privatebrowsing Pin Private Window promo message. BLOCK_MESSAGE will be used in a multi action call after user clicks 'Pin To taskbar'. This will help in hiding Pin promo message on current and preloaded tabs

Differential Revision: https://phabricator.services.mozilla.com/D151888
2022-07-19 23:11:31 +00:00
Jason Prickett
b5104caeed Bug 1779329 - Correcting links and file paths in messaging schema documentation r=barret DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D152201
2022-07-19 20:38:28 +00:00
Jason Prickett
f52d8a768c Bug 1777386 - Special Message Action MULTI_ACTION r=pdahiya
Differential Revision: https://phabricator.services.mozilla.com/D151188
2022-07-14 15:55:02 +00:00
Tooru Fujisawa
54623364da Bug 1777486 - Part 2: Migrate XPCOMUtils.jsm consumers with automatic migration. r=webdriver-reviewers,geckoview-reviewers,preferences-reviewers,application-update-reviewers,pip-reviewers,kmag,owlish,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D151214
2022-07-12 04:21:34 +00:00
Andreea Pavel
7738a75fdd Backed out 11 changesets (Bug 1777486) for failing bc at browser_startup.js on a CLOSED TREE
Backed out changeset b6c4c386f1a6 (Bug 1777486)
Backed out changeset 195cc2de8433 (Bug 1777486)
Backed out changeset 20c746fb1648 (Bug 1777486)
Backed out changeset d5fd8173d62d (Bug 1777486)
Backed out changeset 6d758fab5a3e (Bug 1777486)
Backed out changeset e938b601ba15 (Bug 1777486)
Backed out changeset 0c4ea0b9416b (Bug 1777486)
Backed out changeset 0559c53cc668 (Bug 1777486)
Backed out changeset eea573d3a9f9 (Bug 1777486)
Backed out changeset 9ce3a6496a49 (bug 1777486)
Backed out changeset b0867652fc48 (bug 1777486)
2022-07-11 22:24:40 +03:00
Tooru Fujisawa
8cd6ed7409 Bug 1777486 - Part 2: Migrate XPCOMUtils.jsm consumers with automatic migration. r=webdriver-reviewers,geckoview-reviewers,preferences-reviewers,application-update-reviewers,pip-reviewers,kmag,owlish,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D151214
2022-07-11 15:09:13 +00:00
Tooru Fujisawa
bf93d07148 Bug 1667455 - Part 5: Stop importing Services.jsm from chrome-priv JS code, top-level single-line cases. r=kmag,webdriver-reviewers,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,extension-reviewers,application-update-reviewers,pip-reviewers,twisniewski,m_kato,jdescottes,mconley,AlexandruIonescu,mossop
Differential Revision: https://phabricator.services.mozilla.com/D150894
2022-07-11 12:41:50 +00:00
Tooru Fujisawa
f3a8c52c53 Bug 1667455 - Part 4: Stop importing Services.jsm from JSM. r=kmag,webdriver-reviewers,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,application-update-reviewers,pip-reviewers,twisniewski,devtools-reviewers,m_kato,jdescottes,ochameau,mconley,sfoster,AlexandruIonescu
Differential Revision: https://phabricator.services.mozilla.com/D150893
2022-07-11 12:41:50 +00:00
Jason Prickett
a3f86f284f Bug 1776744 - Add special message action for setting prefs r=pdahiya
Differential Revision: https://phabricator.services.mozilla.com/D150509
2022-07-08 22:47:34 +00:00
Barret Rennie
edfd11a38c Bug 1771073 - Correct FxMS features and keep them up to date with tests r=dmose,pdahiya
The Nimbus Features corresponding to FxMS messaging surfaces are actually
intended to map to FxMS message groups, which can accept *any* FxMS message.
The features have been updated with schemas that accept any FxMS message.

As part of this, all FxMS schemas have been updated with an `$id` so that they
can be bundled into feature schemas and have their internal `$ref`s work.
(Otherwise, a `$ref` would be relative to the top-level schema instead of the
sub-schema).

Schemas for individual message types are no longer exposed as resource:// URIs,
except in tests, as indivual schemas are no longer required at runtime.

Additionally, each FxMS schema has had its `template` field become required and
requires a constant value for that schema (e.g., Spotlight requires a template
value of "spotlight").

A test has been added to ensure that if any of the messaging surfaces schemas
change that the feature schemas are also updated. The feature schemas can be
regenerated via:

```
cd ./browser/components/newtab/content-src/asrouter/schemas
../../../../../../mach make-schemas.py
```

Differential Revision: https://phabricator.services.mozilla.com/D147332
2022-06-29 23:01:37 +00:00
Barret Rennie
7a6ab93418 Bug 1775512 - Do not track SpecialMessageActionSchemas and TriggerActionSchemas from nimbus-shared r=pdahiya
These schemas are only used in Fx Desktop. As such, there is a change in
nimbus-shared to remove the generation of these schemas. The versions in m-c
can now be the canonical versions.

Differential Revision: https://phabricator.services.mozilla.com/D150017
2022-06-23 15:48:12 +00:00
Meg Viar
a3b48ab633 Bug 1754314 - Special message action needed for the private browsing taskbar pin r=emcminn,barret
Differential Revision: https://phabricator.services.mozilla.com/D148436
2022-06-22 17:54:32 +00:00
Tooru Fujisawa
f819cf19b3 Bug 1772101 - Part 21: Use plain object for lazy getter in toolkit/components/messaging-system/. r=pdahiya
Differential Revision: https://phabricator.services.mozilla.com/D147962
2022-06-07 04:30:59 +00:00
Tooru Fujisawa
6b0608c9bd Bug 1772351 - Part 3: Stop calling XPCOMUtils.defineLazyModuleGetters for AppConstants. r=florian,webdriver-reviewers,whimboo,robwu
Differential Revision: https://phabricator.services.mozilla.com/D148166
2022-06-06 04:42:09 +00:00
Tooru Fujisawa
f7650958c8 Bug 1772313 - Part 7: Stop calling XPCOMUtils.defineLazyModuleGetters for Services. r=kmag,webdriver-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D148160
2022-06-06 04:42:06 +00:00
Molnar Sandor
77402a5caa Backed out 15 changesets (bug 1772313, bug 1772351, bug 1772360) for causing xpc failures in telemetry/tests/unit/test_SocketScalars.js CLOSED TREE
Backed out changeset c8b0a2ed239e (bug 1772360)
Backed out changeset 1922adad6abe (bug 1772351)
Backed out changeset 6d3634cce489 (bug 1772351)
Backed out changeset f03968a9d053 (bug 1772351)
Backed out changeset e7a38ef90fe4 (bug 1772351)
Backed out changeset b389e7654771 (bug 1772313)
Backed out changeset 59a33598ff51 (bug 1772313)
Backed out changeset ab60885a8a93 (bug 1772313)
Backed out changeset aad8efac9d05 (bug 1772313)
Backed out changeset 4378e519a8e7 (bug 1772313)
Backed out changeset 302ac54741f8 (bug 1772313)
Backed out changeset 74c59f9fd51c (bug 1772313)
Backed out changeset 575fb877c56c (bug 1772313)
Backed out changeset 2eaa68f10b19 (bug 1772313)
Backed out changeset 4a8b3ba193dc (bug 1772313)
2022-06-06 07:04:25 +03:00
Tooru Fujisawa
b200384ddb Bug 1772351 - Part 3: Stop calling XPCOMUtils.defineLazyModuleGetters for AppConstants. r=florian,webdriver-reviewers,whimboo,robwu
Differential Revision: https://phabricator.services.mozilla.com/D148166
2022-06-06 02:49:13 +00:00
Tooru Fujisawa
fc45e50920 Bug 1772313 - Part 7: Stop calling XPCOMUtils.defineLazyModuleGetters for Services. r=kmag,webdriver-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D148160
2022-06-06 02:49:10 +00:00
Barret Rennie
6ed45f92e8 Bug 1766434 - Make checking for and pinning app to taskbar async on Windows r=bhearsum
Previously `nsIWindowsShellService::{Check,}PinCurrrentAppToTaskbar` was doing
main thread IO. They have been replaced with async versions that do their work
on a background thread.

Differential Revision: https://phabricator.services.mozilla.com/D145244
2022-05-05 18:48:44 +00:00
Paul Zuehlcke
b0377fa482 Bug 1766441 - Remove study prefs set on TCP rollout opt-in/out. r=timhuang
Differential Revision: https://phabricator.services.mozilla.com/D144721
2022-04-27 10:35:50 +00:00
Tim Huang
d008c8e783 Bug 1765949 - Change the search params for TCP rollout. r=pbz
Differential Revision: https://phabricator.services.mozilla.com/D144397
2022-04-22 15:38:14 +00:00
Narcis Beleuzu
49e2102b48 Backed out changeset 4c742ffdfbbf (bug 1765949) as req by timhuang in order to divide the fixes. CLOSED TREE 2022-04-22 18:02:43 +03:00
Tim Huang
51444c2217 Bug 1765949 - Change the search params for TCP rollout. r=pbz
Differential Revision: https://phabricator.services.mozilla.com/D144397
2022-04-22 09:42:40 +00:00
Barret Rennie
97a1c34fda Bug 1759039 - Replace Ajv with JsonSchema.jsm in toolkit/components/messaging-system r=emcminn
Differential Revision: https://phabricator.services.mozilla.com/D142877
2022-04-06 17:07:35 +00:00
Gijs Kruitbosch
8e67201171 Bug 1753696 - Automatic rewrite: replace add_task(setup with add_setup in browser mochitest, r=Standard8,webcompat-reviewers,twisniewski
Differential Revision: https://phabricator.services.mozilla.com/D141437
2022-03-30 16:16:42 +00:00
Norisz Fay
acdd6851cd Backed out 2 changesets (bug 1753696) for causing multiple dt and bc failures CLOSED TREE
Backed out changeset 67fd9edfbcea (bug 1753696)
Backed out changeset a9d957ea887b (bug 1753696)
2022-03-30 12:17:55 +03:00
Gijs Kruitbosch
27039e2946 Bug 1753696 - Automatic rewrite: replace add_task(setup with add_setup in browser mochitest, r=Standard8,webcompat-reviewers,twisniewski
Differential Revision: https://phabricator.services.mozilla.com/D141437
2022-03-30 08:18:51 +00:00
Punam Dahiya
cf81d7ddd3 Bug 1759989 - Intermittent browser_sma_open_spotlight_dialog test fix by restoring stub r=mviar
Differential Revision: https://phabricator.services.mozilla.com/D141393
2022-03-17 19:09:48 +00:00
Ben Hearsum
4a06eb3f49 Bug 1750991: Add support for pinning a a Private Browsing mode shortcut to the Taskbar. r=mhowell
The bulk of this is wiring in a Private Browsing flag in the places that need it, and using some of the recently added WinTaskbar code to grab the correct AUMID. Beyond that, the notable parts are:
* The interface difference between isCurrentAppPinnedToTaskbarAsync and the other changed methods. I was hoping to use the Private Browsing flag everywhere, but doing so in code that run in a separate thread ended up crashing due to the Preferences usage in WinTaskbar (https://searchfox.org/mozilla-central/rev/9d66919569655a8fae9b431550241c058fa85b8a/widget/windows/WinTaskbar.cpp#216)
* The new string for the Private Browsing shortcut. The exact string may change, so it's hardcoded for now.
* Checking the AUMID of shortcuts when looking for a match (to make sure Private Browsing doesn't pick up non-private, and visa versa)
* Some fixes for tests of ShellService.jsm -- I honestly have no idea how these ever passed on Linux.

Differential Revision: https://phabricator.services.mozilla.com/D138196
2022-03-17 16:33:34 +00:00
Punam Dahiya
a76c013839 Bug 1754832 - Update PBM to support opening spotlight tab modal r=Mardak,mviar,fluent-reviewers,flod
Differential Revision: https://phabricator.services.mozilla.com/D140565
2022-03-17 06:41:47 +00:00
Paul Zuehlcke
9e578cb680 Bug 1739619 - Set study prefs for TCP rollout on opt in/out. r=Mardak,anti-tracking-reviewers,timhuang
Differential Revision: https://phabricator.services.mozilla.com/D130466
2021-11-08 13:11:15 +00:00
Andrei Oprea
146d799d27 Bug 1738206 - Add an additional action that enables the pref for TCP section in about:preferences r=pbz
Differential Revision: https://phabricator.services.mozilla.com/D129783
2021-11-01 23:17:01 +00:00
criss
2291e03de3 Backed out 2 changesets (bug 1738206) for causing mochitests failures. CLOSED TREE
Backed out changeset be8c4d9dd03f (bug 1738206)
Backed out changeset 5c003995f9b5 (bug 1738206)
2021-11-01 17:21:06 +02:00
Andrei Oprea
ee4097ed0e Bug 1738206 - Add an additional action that enables the pref for TCP section in about:preferences r=pbz
Differential Revision: https://phabricator.services.mozilla.com/D129783
2021-11-01 14:33:32 +00:00
Andrei Oprea
c73cc990d7 Bug 1730924 - Upgrade ajv.js from 4.1.1 to 6.12.6 r=k88hudson
Differential Revision: https://phabricator.services.mozilla.com/D127625
2021-10-12 19:41:05 +00:00
Alexandru Michis
ba57f54149 Backed out changeset 837ba61b9975 (bug 1730924) for causing xpcshell failures in services/sync.
CLOSED TREE
2021-10-12 20:13:05 +03:00
Andrei Oprea
db4ace8177 Bug 1730924 - Upgrade ajv.js from 4.1.1 to 6.12.6 r=k88hudson
Differential Revision: https://phabricator.services.mozilla.com/D127625
2021-10-12 14:43:02 +00:00
Andrei Oprea
f35336c2cc Bug 1732724 - Report targeting expression source in the case of undesired events r=k88hudson
Differential Revision: https://phabricator.services.mozilla.com/D126776
2021-10-07 19:45:17 +00:00
Alexandru Michis
224d4ba025 Backed out changeset 5d92bd37605f (bug 1732724) for causing xpcshell failures in test_targeting.js
CLOSED TREE
2021-10-07 21:16:39 +03:00
Andrei Oprea
57d4339370 Bug 1732724 - Report targeting expression source in the case of undesired events r=k88hudson
Differential Revision: https://phabricator.services.mozilla.com/D126776
2021-10-07 17:10:27 +00:00
Butkovits Atila
ba1e989261 Backed out changeset bbea0c20d7fe (bug 1732724) for causing Xpcshell failures at test_targeting.js. CLOSED TREE 2021-10-07 19:29:34 +03:00
Andrei Oprea
d9c4a57805 Bug 1732724 - Report targeting expression source in the case of undesired events r=k88hudson
Differential Revision: https://phabricator.services.mozilla.com/D126776
2021-10-07 15:31:29 +00:00
Butkovits Atila
4dad9cc0c3 Backed out changeset 35d10fc51b62 (bug 1732724) for causing failures at test_targeting.js. CLOSED TREE 2021-10-07 17:17:15 +03:00