Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save philipobenito/eb87634523880a11605024e3391b4134 to your computer and use it in GitHub Desktop.
Save philipobenito/eb87634523880a11605024e3391b4134 to your computer and use it in GitHub Desktop.
<?php
class FooTest extends PHPUnit_Framework_Testcase
{
public function testDoSomethingEditsDataAndReturnsArray()
{
$foo = new Foo;
$bar = new Bar;
$user = $foo->doSomething($bar, 1, , 'Phil', 'hello@example.com');
$this->assertInternalType('array', $user, 'The return of (doSomething) was not an array');
// .. assert that Bar has changed the state of the database
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment