izzum\statemachine\StateTest::shouldReturnType PHP Method

shouldReturnType() public method

public shouldReturnType ( )
    public function shouldReturnType()
    {
        $name = 'state-izzum';
        $state = new State($name, State::TYPE_INITIAL);
        $this->assertTrue($state->isInitial());
        $this->assertFalse($state->isFinal());
        $this->assertFalse($state->isNormal());
        $this->assertFalse($state->isRegex());
        $state = new State($name, State::TYPE_NORMAL);
        $this->assertFalse($state->isInitial());
        $this->assertFalse($state->isFinal());
        $this->assertTrue($state->isNormal());
        $this->assertFalse($state->isRegex());
        $state = new State($name, State::TYPE_FINAL);
        $this->assertFalse($state->isInitial());
        $this->assertTrue($state->isFinal());
        $this->assertFalse($state->isNormal());
        $this->assertFalse($state->isRegex());
    }