Skip to content

Commit 6b360f9

Browse files
committed
Contribution guide
1 parent 4eb8586 commit 6b360f9

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

CONTRIBUTING.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Contribution guide
2+
3+
## Running tests
4+
5+
To run the test suite, you need a Google Cloud Storage bucket and a Service Account with a key. You must also set the following environment variables:
6+
7+
* `TEST_GCLOUD_BUCKET` — the name of the bucket.
8+
* `TEST_GCLOUD_CREDENTIALS_PATH` — path to the Service Account's keyfile.
9+
10+
It's best to put these in a `.env` file so that you don't have to supply these variables over and over. The test suite automatically loads environment variables from `.env`.
11+
12+
Then run the test suite with:
13+
14+
~~~bash
15+
bundle exec rspec
16+
~~~

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,3 +154,7 @@ DistributedLock::GoogleCloudStorage::Lock(
154154
logger: logger,
155155
)
156156
~~~
157+
158+
## Contributing
159+
160+
Please read the [Contribution guide](CONTRIBUTING.md).

spec/spec_helper.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# frozen_string_literal: true
2+
13
require 'dotenv'
24
require 'google/cloud/errors'
35
require 'rspec/retry'

0 commit comments

Comments
 (0)