From 710f2c7bb046b43ec9878ae795a181101f6d7515 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Sat, 5 Sep 2015 23:30:56 -0400 Subject: Improve unit tests --- tests/units/TextHelperTest.php | 56 ------------------------------------------ 1 file changed, 56 deletions(-) delete mode 100644 tests/units/TextHelperTest.php (limited to 'tests/units/TextHelperTest.php') diff --git a/tests/units/TextHelperTest.php b/tests/units/TextHelperTest.php deleted file mode 100644 index 95c83e57..00000000 --- a/tests/units/TextHelperTest.php +++ /dev/null @@ -1,56 +0,0 @@ -container); - - $this->assertEquals('

Test

', $h->markdown('Test')); - - $this->assertEquals( - '

Task #123

', - $h->markdown('Task #123') - ); - - $this->assertEquals( - '

Task #123

', - $h->markdown('Task #123', array('controller' => 'a', 'action' => 'b', 'params' => array('c' => 'd'))) - ); - - $this->assertEquals( - '

Check that: http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags/1732454#1732454

', - $h->markdown( - 'Check that: http://stackoverflow.com/questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags/1732454#1732454', - array('controller' => 'a', 'action' => 'b', 'params' => array('c' => 'd')) - ) - ); - } - - public function testFormatBytes() - { - $h = new Text($this->container); - - $this->assertEquals('1k', $h->bytes(1024)); - $this->assertEquals('33.71k', $h->bytes(34520)); - } - - public function testContains() - { - $h = new Text($this->container); - - $this->assertTrue($h->contains('abc', 'b')); - $this->assertFalse($h->contains('abc', 'd')); - } - - public function testInList() - { - $h = new Text($this->container); - $this->assertEquals('?', $h->in('a', array('b' => 'c'))); - $this->assertEquals('c', $h->in('b', array('b' => 'c'))); - } -} -- cgit v1.2.3