MarketSquare / robotframework-aws

Custom Library for Robot Framework to interact with Amazon Cloud Services
MIT License
26 stars 21 forks source link

Test development workflow with Localstack #17

Closed teaglebuilt closed 3 months ago

teaglebuilt commented 4 years ago

LocalStack is a service that enables local interaction with AWS Services without associated costs and real accounts. This is available through docker and for the purpose of developing keywords without having to use personal accounts. This is not a must.

In fact, it has not even been tested. What needs to be verified is the interaction with boto3 and if it will be a positive attribute to the development workflow. We can still use our AWS accounts with Boto3 to build out our keywords. Though this might prove to be a better option? At this point I have no idea...

Questions:

  1. Does it work with boto3?
  2. Can or how could it be used for accurate unit testing?
  3. Do we want to use it?
adrianyorke commented 4 years ago

Looks good! I have been testing with my work AWS account so far but I agree a local solution would be great and this solution does seem to be very popular/active. It should definitely work with boto3 and AWS CLI, otherwise I guess there is no point? Credentials are interesting (see the article below).

There's a good write-up here on how to get LocalStack up and running on your machine: https://dev.to/goodidea/how-to-fake-aws-locally-with-localstack-27me

My issue is that I can't run Docker containers at the same time as VMs. My database and OSX development machines are VMs.

teaglebuilt commented 4 years ago

ok, i think this would just be an option then. No tests should rely on the container then.

adrianyorke commented 4 years ago

Actually, I think it's a good idea. Perhaps have a look how other projects are doing it? I just have some challenges on my local machine but I could install LocalStack elsewhere on another machine for example or switch to docker mode when working on aws stuff. It would be great to have CI tests that use LocalStack as a way of checking syntax for example.

adrianyorke commented 4 years ago

Also consider s3mock: https://hub.docker.com/r/adobe/s3mock

Mentioned in PR24: https://github.com/teaglebuilt/robotframework-aws/pull/24