Pick up new events API
This commit is contained in:
parent
ce31969a44
commit
c6f7ae1677
7 changed files with 17 additions and 17 deletions
|
|
@ -42,7 +42,7 @@ export class MockAgent extends MockClient {
|
|||
"Connection check failed"
|
||||
);
|
||||
|
||||
this.client.logger.addOnMessageListener((logLine: LogLine) => {
|
||||
this.client.logger.onLogEmitted.add((logLine: LogLine) => {
|
||||
const state = this.client.getSettings().isSyncEnabled
|
||||
? "(online) "
|
||||
: "(offline)";
|
||||
|
|
@ -198,14 +198,14 @@ export class MockAgent extends MockClient {
|
|||
);
|
||||
this.client.logger.info(
|
||||
"Local files: " +
|
||||
Array.from(otherAgent.localFiles.keys()).join(", ")
|
||||
Array.from(otherAgent.localFiles.keys()).join(", ")
|
||||
);
|
||||
otherAgent.client.logger.info(
|
||||
"Local data: " + JSON.stringify(otherAgent.data, null, 2)
|
||||
);
|
||||
otherAgent.client.logger.info(
|
||||
"Local files: " +
|
||||
Array.from(otherAgent.localFiles.keys()).join(", ")
|
||||
Array.from(otherAgent.localFiles.keys()).join(", ")
|
||||
);
|
||||
|
||||
throw e;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue