Elgg\CommitMessageTest::testCanParseMessagesWithOneLineBody PHP Method

testCanParseMessagesWithOneLineBody() public method

    public function testCanParseMessagesWithOneLineBody()
    {
        $text = "chore(test): Summary\nOptional body";
        $msg = new CommitMessage($text);
        $this->assertTrue($msg->isValidFormat());
        $this->assertSame('chore', $msg->getPart('type'));
        $this->assertSame('test', $msg->getPart('component'));
        $this->assertSame('Summary', $msg->getPart('summary'));
        $this->assertSame('Optional body', $msg->getPart('body'));
    }