Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crowdAI tests should use mock services #1094

Open
spMohanty opened this issue Dec 3, 2018 · 4 comments
Open

crowdAI tests should use mock services #1094

spMohanty opened this issue Dec 3, 2018 · 4 comments

Comments

@spMohanty
Copy link
Member

Some of the tests currently use services like AWS S3 etc, and hence the travis configuration needs us to give sensitive keys as environment variable.
As a result, the tests running on pull requests by external contributors etc fail.

We should replace all such service instance by mock service.
For instance all AWS S3 related stuff could be proxied through this S3 mock service : https://github.com/jkrall/mock-aws-s3

@spMohanty
Copy link
Member Author

@mridulnagpal : Can you have a look at this ?

@spMohanty
Copy link
Member Author

spMohanty commented Dec 4, 2018

This build triggered by my account passes : https://travis-ci.org/crowdAI/crowdai/builds/463024480

And these are the env variables which are set by secret keys :

# Setting environment variables from repository settings
$ export AWS_S3_BUCKET=[secure]
$ export GRADER=[secure]
$ export SMTP_ADDRESS=[secure]
$ export SMTP_DOMAIN=[secure]
$ export DEVISE_SECRET_KEY=[secure]
$ export SECRET_KEY_BASE=[secure]
$ export MANDRILL_KEY=[secure]
$ export MAILCHIMP_API_KEY=[secure]
$ export MAILCHIMP_LIST_ID=[secure]
$ export MAILCHIMP_INBOUND_API_KEY=[secure]
$ export CROWDAI_API_KEY=[secure]
$ export AWS_S3_SHARED_BUCKET=[secure]
$ export AWS_REGION=[secure]
$ export AWS_ACCESS_KEY_ID=[secure]
$ export AWS_SECRET_ACCESS_KEY=[secure]
$ export HOST=[secure]

@mridulnagpal
Copy link
Contributor

@spMohanty On it!

@mridulnagpal
Copy link
Contributor

So I did everything according to the documentation, but there seems to be a problem. After just including the gem to our gemfile, I get an error while running bundle exec rake parallel:setup . @natejenkins Any suggestions on what might be the issue?

error-aws

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants