Exemplo n.º 1
0
 function test_get_last_commit()
 {
     $commit = new Commit(WP_Gistpen::$plugin_name, WP_Gistpen::$version);
     $commit->set_ID(1);
     $this->mock_commit->shouldReceive('get_ID')->once()->andReturn(2);
     $this->history->set_commits(array(1 => $commit, 2 => $this->mock_commit));
     $this->assertNotEquals($commit, $this->history->get_last_commit());
 }