mirror of https://github.com/Hypfer/Valetudo.git
30 lines
719 B
JavaScript
30 lines
719 B
JavaScript
const PendingMapChangeHandlingCapability = require("../../../core/capabilities/PendingMapChangeHandlingCapability");
|
|
|
|
/**
|
|
* @extends PendingMapChangeHandlingCapability<import("../MockRobot")>
|
|
*/
|
|
class MockPendingMapChangeHandlingCapability extends PendingMapChangeHandlingCapability {
|
|
/**
|
|
* @returns {Promise<boolean>}
|
|
*/
|
|
async hasPendingChange() {
|
|
return this.robot?.state?.map?.metaData?.pendingMapChange === true;
|
|
}
|
|
|
|
/**
|
|
* @returns {Promise<void>}
|
|
*/
|
|
async acceptChange() {
|
|
//intentional
|
|
}
|
|
|
|
/**
|
|
* @returns {Promise<void>}
|
|
*/
|
|
async rejectChange() {
|
|
//intentional
|
|
}
|
|
}
|
|
|
|
module.exports = MockPendingMapChangeHandlingCapability;
|