You are here

public function MappedObjectTest::testPullException in Salesforce Suite 8.3

Same name and namespace in other branches
  1. 8.4 modules/salesforce_mapping/tests/src/Unit/MappedObjectTest.php \Drupal\Tests\salesforce_mapping\Unit\MappedObjectTest::testPullException()
  2. 5.0.x modules/salesforce_mapping/tests/src/Unit/MappedObjectTest.php \Drupal\Tests\salesforce_mapping\Unit\MappedObjectTest::testPullException()

@covers ::pull @expectedException \Drupal\salesforce\Exception

File

modules/salesforce_mapping/tests/src/Unit/MappedObjectTest.php, line 255

Class

MappedObjectTest
Test Mapped Object instantitation.

Namespace

Drupal\Tests\salesforce_mapping\Unit

Code

public function testPullException() {
  $this->mapped_object
    ->expects($this
    ->any())
    ->method('sfid')
    ->willReturn(FALSE);
  $this->mapping
    ->expects($this
    ->any())
    ->method('hasKey')
    ->willReturn(FALSE);
  $this->mapped_object
    ->pull();
}