| AboutPreferences.test.js |
|
26898 |
- |
| ActivityStream.test.js |
), and the
// assertions below only care that the factory registered for each pref returns
// a feed.
function feedStubs() {
return {
AboutPreferences: class AboutPreferences {},
DiscoveryStreamFeed: class DiscoveryStreamFeed {},
FaviconFeed: class FaviconFeed {},
HighlightsFeed: class HighlightsFeed {},
NewTabInit: class NewTabInit {},
PlacesFeed: class PlacesFeed {},
PrefsFeed: class PrefsFeed {},
SectionsFeed: class SectionsFeed {},
SystemTickFeed: class SystemTickFeed {},
TelemetryFeed: class TelemetryFeed {},
TopSitesFeed: class TopSitesFeed {},
TopStoriesFeed: class TopStoriesFeed {},
};
}
function FakeStore() {
return { init: jest.fn(), uninit: jest.fn(), feeds: { get: () => {} } };
}
// Enough of DefaultPrefs for the dynamic pref computation: it reads back
// whatever default was last written for a pref.
class FakeDefaultPrefs {
constructor(config) {
this._config = config;
this._values = new Map();
this.init = jest.fn();
}
get(name) {
return this._values.get(name);
}
set(name, value) {
this._values.set(name, value);
}
}
/**
A jest.fn() with sinon's withArgs semantics: the first matching argument
prefix wins, and anything unmatched falls through to `fallback`.
@param {Function} fallback Implementation for unmatched calls.
@returns {Function} jest.fn() with an extra whenCalledWith(...args) helper.
|
45566 |
- |
| ActivityStreamMessageChannel.test.js |
|
16630 |
- |
| ActivityStreamPrefs.test.js |
|
5219 |
- |
| DiscoveryStreamFeed.test.js |
|
128584 |
- |
| DownloadsManager.test.js |
|
17121 |
- |
| FaviconFeed.test.js |
|
2094 |
- |
| InferredModel |
|
|
- |
| NewTabInit.test.js |
|
2660 |
- |
| PersistentCache.test.js |
|
4620 |
- |
| PrefsFeed.test.js |
|
75645 |
- |
| Screenshots.test.js |
|
8114 |
- |
| SectionsManager.test.js |
|
29833 |
- |
| SiteClassifier.test.js |
|
6174 |
- |
| SystemTickFeed.test.js |
|
3352 |
- |
| Wallpapers |
|
|
- |
| WebNotificationsFeed.test.js |
|
12457 |
- |
| Widgets |
|
|
- |