Inheritance: extends Provider, use trait seregazhuk\PinterestBot\Helpers\Providers\Traits\FollowTrait
Esempio n. 1
0
 /** @test */
 public function unFollowInterest()
 {
     $request = $this->createSuccessApiResponse();
     $error = $this->createErrorApiResponse();
     $this->mock->shouldReceive('followMethodCall')->once()->andReturn($request);
     $this->mock->shouldReceive('followMethodCall')->once()->andReturn($error);
     $this->assertTrue($this->provider->unFollow(1111));
     $this->assertFalse($this->provider->unFollow(1111));
 }
 public function testUnFollow()
 {
     $request = $this->createSuccessApiResponse();
     $error = $this->createErrorApiResponse();
     $this->mock->expects($this->at(1))->method('exec')->willReturn($request);
     $this->mock->expects($this->at(3))->method('exec')->willReturn($error);
     $this->assertTrue($this->provider->unFollow(1111));
     $this->assertFalse($this->provider->unFollow(1111));
 }
 /** @test */
 public function it_should_return_generator_for_pins()
 {
     $this->apiShouldReturnPagination()->apiShouldReturnEmpty()->assertCount(2, iterator_to_array($this->provider->pins('test')));
 }