Pantheon\Terminus\UnitTests\Commands\Workflow\ListCommandTest::testListCommand PHP Method

testListCommand() public method

Tests the workflow:list command.
public testListCommand ( )
    public function testListCommand()
    {
        $this->workflows->expects($this->once())->method('fetch')->willReturn(null);
        $this->workflows->expects($this->once())->method('all')->willReturn([$this->workflow]);
        $this->workflow->expects($this->once())->method('serialize')->willReturn(['id' => '12345', 'details' => 'test']);
        $out = $this->command->wfList('mysite');
        foreach ($out as $w) {
            $this->assertEquals($w['id'], '12345');
            $this->assertEquals($w['details'], 'test');
        }
    }