mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-23 22:11:09 +03:00
Fixed mock instantiation
This mock will fail by default now, which stops us from adding bad data in prod.
This commit is contained in:
parent
833182bc7f
commit
68f469c78b
@ -62,29 +62,23 @@ module.exports = {
|
||||
|
||||
this.controller.init({api});
|
||||
|
||||
this.controller.receive({
|
||||
data: {
|
||||
source: 'https://brid.gy/repost/twitter/KiaKamgar/1615735511137624064/1615738476875366401',
|
||||
target: 'https://ronald.com/pizza/',
|
||||
extra: 'data'
|
||||
const addMocks = () => {
|
||||
if (!urlService.hasFinished()) {
|
||||
setTimeout(addMocks, 100);
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
||||
this.controller.receive({
|
||||
data: {
|
||||
source: 'https://slrpnk.net/post/222314',
|
||||
target: 'https://ronald.com/thing/',
|
||||
extra: 'data'
|
||||
}
|
||||
});
|
||||
this.controller.receive({
|
||||
data: {
|
||||
source: 'https://brid.gy/repost/twitter/KiaKamgar/1615735511137624064/1615738476875366401',
|
||||
target: 'https://valid-url-for-your.site'
|
||||
}
|
||||
});
|
||||
|
||||
this.controller.receive({
|
||||
data: {
|
||||
source: 'https://lobste.rs/s/eq4f9d',
|
||||
target: 'https://ronald.com/whatever/',
|
||||
extra: 'data'
|
||||
}
|
||||
});
|
||||
return;
|
||||
};
|
||||
|
||||
addMocks();
|
||||
|
||||
const sendingService = new MentionSendingService({
|
||||
discoveryService,
|
||||
|
Loading…
Reference in New Issue
Block a user