Last active
December 21, 2015 21:48
-
-
Save jubianchi/6370371 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| <?php | |
| namespace { | |
| class A { | |
| private $sep; | |
| public function __construct($sep = null) { | |
| $this->sep = $sep ?: '--'; | |
| } | |
| public function concat($a, $b) { | |
| return $a . $this->sep . $b; | |
| } | |
| } | |
| } | |
| namespace tests\units { | |
| use atoum; | |
| class A extends atoum { | |
| public function testConcat() { | |
| $this | |
| ->if($object = new \mock\A()) | |
| ->then | |
| ->string($object->concat('foo', 'bar'))->isEqualTo('foo--bar') | |
| ; | |
| } | |
| } | |
| } |
Author
jubianchi
commented
Aug 28, 2013
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment