-
-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d54c56d
commit f7a3e6d
Showing
5 changed files
with
326 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
namespace spec\PUGX\Poser\Calculator; | ||
|
||
use PhpSpec\ObjectBehavior; | ||
|
||
class GDTextSizeCalculatorSpec extends ObjectBehavior | ||
{ | ||
public function it_should_compute_text_width(): void | ||
{ | ||
$this->calculateWidth('MIT', 8)->shouldBeLike(24.0); | ||
$this->calculateWidth('MIT', 10)->shouldBeLike(29.0); | ||
$this->calculateWidth('MIT', 14)->shouldBeLike(34.0); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
namespace spec\PUGX\Poser\Calculator; | ||
|
||
use PhpSpec\ObjectBehavior; | ||
|
||
class SvgTextSizeCalculatorSpec extends ObjectBehavior | ||
{ | ||
public function it_should_compute_text_width(): void | ||
{ | ||
$this->calculateWidth('MIT', 8)->shouldBeLike(24.1); | ||
$this->calculateWidth('MIT', 10)->shouldBeLike(27.7); | ||
$this->calculateWidth('MIT', 14)->shouldBeLike(34.8); | ||
} | ||
} |
Oops, something went wrong.