/** * Tests putItem method with required attributes only. */ public function testPutItem() { $this->if($awsClient = $this->createAwsClientMock())->and($awsClient->getMockController()->putItem = null)->and($client = new Base($awsClient))->and($client->putItem($tableName = uniqid(), $item = $client->formatAttributes(['id' => 1234, 'title' => 'Clip de test'], Attribute::FORMAT_PUT)))->then->mock($awsClient)->call('putItem')->withArguments(['TableName' => $tableName, 'Item' => ['id' => ['N' => 1234], 'title' => ['S' => 'Clip de test']], 'ConditionnalOperator' => 'AND', 'ReturnValues' => 'NONE', 'ReturnConsumedCapacity' => 'NONE', 'ReturnItemCollectionMetrics' => 'NONE'])->once(); }