@serenity-js/core
Version:
The core Serenity/JS framework, providing the Screenplay Pattern interfaces, as well as the test reporting and integration infrastructure
26 lines • 1.04 kB
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.SceneTemplateDetected = void 0;
const tiny_types_1 = require("tiny-types");
const model_1 = require("../model");
const screenplay_1 = require("../screenplay");
const DomainEvent_1 = require("./DomainEvent");
/**
* @group Events
*/
class SceneTemplateDetected extends DomainEvent_1.DomainEvent {
sceneId;
template;
static fromJSON(o) {
return new SceneTemplateDetected(model_1.CorrelationId.fromJSON(o.sceneId), model_1.Description.fromJSON(o.template), screenplay_1.Timestamp.fromJSON(o.timestamp));
}
constructor(sceneId, template, timestamp) {
super(timestamp);
this.sceneId = sceneId;
this.template = template;
(0, tiny_types_1.ensure)('sceneId', sceneId, (0, tiny_types_1.isDefined)());
(0, tiny_types_1.ensure)('template', template, (0, tiny_types_1.isDefined)());
}
}
exports.SceneTemplateDetected = SceneTemplateDetected;
//# sourceMappingURL=SceneTemplateDetected.js.map
;