Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

apply transitions verification to built project #154

Merged
merged 1 commit into from
Mar 21, 2021

Conversation

Denire
Copy link
Contributor

@Denire Denire commented Mar 18, 2021

Bug description:
We have a verification method to check if all transitions are correct and lead to existing states. The problem is that if we have non-isolated scenarios with cross-dependencies we cannot verify fromState transitions as these states are in separate scenario.

Example scenario with bug:

val NotIsolatedScenario = Scenario {
    state("second") {
        activators(fromState = "/first") { // fails verification 
            regex("ok")
        }
    }
}
val BugScenario = Scenario(telephony) {
    append(NotIsolatedScenario)
    state("first") {
        activators(fromState = "/second") {
            regex("ok")
        }
    }
}
fun main(args: Array<String>) {
    BotEngine(BugScenario)
}

Solution:
Execute verification only on complete ScenarioModel.

@Denire Denire merged commit 04b0e5e into master Mar 21, 2021
@Denire Denire deleted the fix/scenario-model-verification branch March 21, 2021 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants