summaryrefslogtreecommitdiffstats
path: root/browser/components/newtab/docs/v2-system-addon
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:14:29 +0000
commitfbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8 (patch)
tree4c1ccaf5486d4f2009f9a338a98a83e886e29c97 /browser/components/newtab/docs/v2-system-addon
parentReleasing progress-linux version 124.0.1-1~progress7.99u1. (diff)
downloadfirefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.tar.xz
firefox-fbaf0bb26397aa498eb9156f06d5a6fe34dd7dd8.zip
Merging upstream version 125.0.1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'browser/components/newtab/docs/v2-system-addon')
-rw-r--r--browser/components/newtab/docs/v2-system-addon/preferences.md2
-rw-r--r--browser/components/newtab/docs/v2-system-addon/unit_testing_guide.md8
2 files changed, 5 insertions, 5 deletions
diff --git a/browser/components/newtab/docs/v2-system-addon/preferences.md b/browser/components/newtab/docs/v2-system-addon/preferences.md
index ec6ba82491..d709e830e4 100644
--- a/browser/components/newtab/docs/v2-system-addon/preferences.md
+++ b/browser/components/newtab/docs/v2-system-addon/preferences.md
@@ -43,7 +43,7 @@ pref in the following files:
You can see an example in [this patch](https://github.com/mozilla/activity-stream/pull/2977).
-## Reading, setting, and observing preferences from `.jsm`s
+## Reading, setting, and observing preferences from `.sys.mjs`s
To read/set/observe Activity Stream preferences, construct a `Prefs` instance found in `lib/ActivityStreamPrefs.sys.mjs`.
diff --git a/browser/components/newtab/docs/v2-system-addon/unit_testing_guide.md b/browser/components/newtab/docs/v2-system-addon/unit_testing_guide.md
index c3dd369a2d..bc0b2e8b53 100644
--- a/browser/components/newtab/docs/v2-system-addon/unit_testing_guide.md
+++ b/browser/components/newtab/docs/v2-system-addon/unit_testing_guide.md
@@ -4,7 +4,7 @@
Our unit tests in Activity Stream are written with mocha, chai, and sinon, and run
with karma. They include unit tests for both content code (React components, etc.)
-and `.jsm`s.
+and `.sys.mjs`s.
You can find unit tests in `tests/unit`.
@@ -32,7 +32,7 @@ If you are creating a new test, add it to a subdirectory of the `tests/unit`
that corresponds to the file you are testing. Tests should end with `.test.js` or
`.test.jsx` if the test includes any jsx.
-For example, if the file you are testing is `lib/Foo.jsm`, the test
+For example, if the file you are testing is `lib/Foo.sys.mjs`, the test
file should be `test/unit/lib/Foo.test.js`
## Mocha tests
@@ -96,9 +96,9 @@ assert.isUserEventAction({type: "FOO"});
assert.isUserEventAction(ac.UserEvent({event: "BLOOP"}));
```
-## Overriding globals in `.jsm`s
+## Overriding globals in `.sys.mjs`s
-Most `.jsm`s you will be testing use `Cu.import` or `XPCOMUtils` to inject globals.
+Most `.sys.mjs`s you will be testing use `Cu.import` or `XPCOMUtils` to inject globals.
In order to add mocks/stubs/fakes for these globals, you should use the `GlobalOverrider`
utility in `test/unit/utils`: