test(step): write tests for getApp, test, getLastExecutionStep and getNextStep

This commit is contained in:
Ali BARIN
2024-11-04 11:43:25 +00:00
parent 71bc7a62c2
commit 42c2131144
2 changed files with 54 additions and 6 deletions

View File

@@ -160,12 +160,7 @@ class Step extends Base {
}
async getLastExecutionStep() {
const lastExecutionStep = await this.$relatedQuery('executionSteps')
.orderBy('created_at', 'desc')
.limit(1)
.first();
return lastExecutionStep;
return await this.$relatedQuery('lastExecutionStep');
}
async getNextStep() {