8

How do you create test orders and test the workflow of this extension for Amazon integration in a test environment?

I was told there is no possibility to create test orders and although I was told by support that it is possible to import the real orders into multiple environments without affecting the live system (means: if an order is imported in the test environment it still will also be imported in the live environment) this doesn't work like I imagine it should at all.

When I execute the cron job in the test environment sometimes a few orders are imported but I cannot tell why sometimes orders are imported and sometimes not. The cronjob runs quite some time (> 100 seconds) but I end up without any new orders most of the time.

At the same time hundreds of orders are created by customers so there should be plenty to import.

[Update] It was pointed out to me that the frequency / delay of imports may be influenced by the load at Amazon. I didn't think about that. The other points (is it possible to create test orders / is there a sandbox / how do you debug the extension) are still valid. [/Update]

This makes it impossible to debug problems with the extension. The support returns not-so-helpful one-line answers so I'm turning to the community to help me out on this: what are your best practices?

5

I learned from M2ePro support that it is hard to test this. Be very careful whatever you are doing.

Some information I got:

  • If you copy your production database back to your development environment, don't delete the production merchant account in your development environment. If you do this you will lose all data associated to this account.

  • If you setup both the development and production merchant accounts in your database you cannot have only one of them talk to Amazon. It's all or nothing.

  • You should create separate merchant accounts and M2ePro extension license keys for dev/live. Otherwise one may affect the other even in situations where you wouldn't believe there is communication happening.

  • You can deactivate channels (e.g. System > Configuration > M2E Pro > Channels > Other Channels > Amazon (Beta)) in one environment without affecting the other environments.

For us this means that we deactivate the channel in non-production environments and only activate it if we really need to. If we activate the channel we stop the automatic execution of cronjobs related to M2ePro and trigger executions manually.

We built some mechanisms that make sure a non-production environment is configured correctly and can't talk to Amazon by accident. Mocking the whole marketplace communictation is out of scope for us at the moment.

You may be able to directly delete the production merchant account from the database bypassing Magento without doing harm but that's anyone guess.

  • can you add more info about which cron job import order ? and if it is possible to trigger it on a local environment so that I can debug it with Xdebug ? – Fra May 20 '14 at 9:18
  • I have added some steps to use xdebug on a local environment here: magento.stackexchange.com/questions/21093/… – Fra Jun 3 '14 at 18:50
  • Sorry I missed your question. There is only one M2ePro-Cronjob but we also have custom question cronjob working with these orders. Thanks for the explanation how to debug in your question. Did you test this with Amazon too or is it eBay-only? – Matthias Zeis Jun 4 '14 at 8:19
  • it works with both but I need to change my answer: the best option is to create a separate M2E licence for your development environment otherwise you risk to have problem with the live license – Fra Jun 5 '14 at 9:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.