Metabor\Statemachine\Condition\AndCompositeTest::testCombinesTheInnerConditionWithAnd PHP Method

testCombinesTheInnerConditionWithAnd() public method

    public function testCombinesTheInnerConditionWithAnd()
    {
        $instance = $this->createTestInstance();
        $subject = new \stdClass();
        $context = new \ArrayIterator();
        $result = $instance->checkCondition($subject, $context);
        $this->assertTrue($result);
        $instance->addAnd(new Contradiction('Other Condition'));
        $result = $instance->checkCondition($subject, $context);
        $this->assertFalse($result);
    }