Code Duplication    Length = 18-19 lines in 3 locations

src/OroCRM/Bundle/MagentoBundle/Tests/Functional/Fixture/CopyCustomerAddressToContact/LoadMagentoChannel.php 1 location

@@ 144-161 (lines=18) @@
141
    /**
142
     * @return $this
143
     */
144
    protected function createTransport()
145
    {
146
        $transport = new MagentoSoapTransport;
147
        $transport->setAdminUrl('http://localhost/magento/admin');
148
        $transport->setApiKey('key');
149
        $transport->setApiUser('user');
150
        $transport->setIsExtensionInstalled(true);
151
        $transport->setExtensionVersion(SoapTransport::REQUIRED_EXTENSION_VERSION);
152
        $transport->setMagentoVersion('1.9.1.0');
153
        $transport->setIsWsiMode(false);
154
        $transport->setWebsiteId('1');
155
        $transport->setWsdlUrl('http://localhost/magento/api/v2_soap?wsdl=1');
156
        $transport->setWebsites([['id' => 1, 'label' => 'Website ID: 1, Stores: English, French, German']]);
157
        $this->em->persist($transport);
158
        $this->transport = $transport;
159
160
        return $this;
161
    }
162
    /**
163
     * @param $region
164
     * @param $country

src/OroCRM/Bundle/MagentoBundle/Tests/Functional/Fixture/LoadMagentoChannel.php 1 location

@@ 272-290 (lines=19) @@
269
    /**
270
     * @return $this
271
     */
272
    protected function createTransport()
273
    {
274
        $transport = new MagentoSoapTransport;
275
        $transport->setAdminUrl('http://localhost/magento/admin');
276
        $transport->setApiKey('key');
277
        $transport->setApiUser('user');
278
        $transport->setIsExtensionInstalled(true);
279
        $transport->setExtensionVersion(SoapTransport::REQUIRED_EXTENSION_VERSION);
280
        $transport->setMagentoVersion('1.9.1.0');
281
        $transport->setIsWsiMode(false);
282
        $transport->setWebsiteId('1');
283
        $transport->setWsdlUrl('http://localhost/magento/api/v2_soap?wsdl=1');
284
        $transport->setWebsites([['id' => 1, 'label' => 'Website ID: 1, Stores: English, French, German']]);
285
286
        $this->em->persist($transport);
287
        $this->transport = $transport;
288
289
        return $this;
290
    }
291
292
    /**
293
     * @param $region

src/OroCRM/Bundle/MagentoBundle/Tests/Functional/Fixture/ResyncMagentoCustomerAddresses/LoadMagentoChannel.php 1 location

@@ 191-208 (lines=18) @@
188
    /**
189
     * @return $this
190
     */
191
    protected function createTransport()
192
    {
193
        $transport = new MagentoSoapTransport;
194
        $transport->setAdminUrl('http://localhost/magento/admin');
195
        $transport->setApiKey('key');
196
        $transport->setApiUser('user');
197
        $transport->setIsExtensionInstalled(true);
198
        $transport->setExtensionVersion(SoapTransport::REQUIRED_EXTENSION_VERSION);
199
        $transport->setMagentoVersion('1.9.1.0');
200
        $transport->setIsWsiMode(false);
201
        $transport->setWebsiteId('1');
202
        $transport->setWsdlUrl('http://localhost/magento/api/v2_soap?wsdl=1');
203
        $transport->setWebsites([['id' => 1, 'label' => 'Website ID: 1, Stores: English, French, German']]);
204
        $this->em->persist($transport);
205
        $this->transport = $transport;
206
207
        return $this;
208
    }
209
210
    /**
211
     * @param $region