[ 'createMissing' => true ], 'hosts' => [ 'updateExisting' => true, 'createMissing' => true ], 'items' => [ 'updateExisting' => true, 'createMissing' => true ], 'discoveryRules' => [ 'updateExisting' => true, 'createMissing' => true ] ]; $this->call('configuration.import', [ 'format' => 'xml', 'source' => $source, 'rules' => $rules ], null); $this->assertEquals(2, CDBHelper::getCount( 'SELECT NULL'. ' FROM hstgrp'. ' WHERE name IN (\'Master group\', \'12345\')' )); $this->assertEquals(2, CDBHelper::getCount( 'SELECT NULL'. ' FROM hosts'. ' WHERE host IN (\'Host having discovered hosts\', \'12345\')' )); } }