📅  最后修改于: 2022-03-11 14:48:36.541000             🧑  作者: Mango
public static mockGetProfile(){
const response = JSON.parse(`
"name": "abc",
"active": true,
...all other json fields that you want
`);
let obs = new Observable((subscriber) => {
setTimeout(()=>{
subscriber.next(response);
subscriber.complete();
}, 3000);
});
return obs;
}