I began my attempt to understand this library by using tests. During this brief effort, I was able to abstract the setup into env.sh file and use a promises library to demo usage of one product api endpoint.
I want to contribute this back in hopes that it will help others and perhaps even lead to more test related contributions.
For example, one key behavior that I learned about this library was that it does not return an ErrorResponse from amazon via reject! It is debatable whether that is desirable or not ... but it definitely becomes easier to spot and accept as the current behaviour when tests fail.
I began my attempt to understand this library by using tests. During this brief effort, I was able to abstract the setup into
env.sh
file and use a promises library to demo usage of one product api endpoint.I want to contribute this back in hopes that it will help others and perhaps even lead to more test related contributions.
For example, one key behavior that I learned about this library was that it does not return an
ErrorResponse
from amazon viareject
! It is debatable whether that is desirable or not ... but it definitely becomes easier to spot and accept as the current behaviour when tests fail.