Skip to content

Commit 1ae634d

Browse files
ashtulgkorland
authored andcommitted
bloom client + tests (#1)
Initial RedisBloom client + tests
1 parent 4172579 commit 1ae634d

File tree

8 files changed

+1058
-0
lines changed

8 files changed

+1058
-0
lines changed

Diff for: .circleci/config.yml

+99
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
2+
# Python CircleCI 2.0 configuration file
3+
#
4+
# Check https://circleci.com/docs/2.0/language-python/ for more details
5+
#
6+
version: 2
7+
jobs:
8+
build:
9+
docker:
10+
- image: circleci/python:3.7.1
11+
- image: redislabs/rebloom:edge
12+
13+
working_directory: ~/repo
14+
15+
steps:
16+
- checkout
17+
18+
- restore_cache: # Download and cache dependencies
19+
keys:
20+
- v1-dependencies-{{ checksum "requirements.txt" }}
21+
# fallback to using the latest cache if no exact match is found
22+
- v1-dependencies-
23+
24+
- run:
25+
name: install dependencies
26+
command: |
27+
virtualenv venv
28+
. venv/bin/activate
29+
pip install -r requirements.txt
30+
pip install codecov
31+
32+
- save_cache:
33+
paths:
34+
- ./venv
35+
key: v1-dependencies-{{ checksum "requirements.txt" }}
36+
37+
- run:
38+
name: run tests
39+
command: |
40+
. venv/bin/activate
41+
REDIS_PORT=6379 coverage run test_commands.py
42+
codecov
43+
44+
- store_artifacts:
45+
path: test-reports
46+
destination: test-reports
47+
48+
build_nightly:
49+
docker:
50+
- image: circleci/python:3.7.1
51+
- image: redislabs/rebloom:edge
52+
53+
working_directory: ~/repo
54+
55+
steps:
56+
- checkout
57+
58+
- restore_cache: # Download and cache dependencies
59+
keys:
60+
- v1-dependencies-{{ checksum "requirements.txt" }}
61+
# fallback to using the latest cache if no exact match is found
62+
- v1-dependencies-
63+
64+
- run:
65+
name: install dependencies
66+
command: |
67+
virtualenv venv
68+
. venv/bin/activate
69+
pip install -r requirements.txt
70+
pip install codecov
71+
72+
- save_cache:
73+
paths:
74+
- ./venv
75+
key: v1-dependencies-{{ checksum "requirements.txt" }}
76+
77+
- run:
78+
name: run tests
79+
command: |
80+
. venv/bin/activate
81+
REDIS_PORT=6379 python test_commands.py
82+
83+
# no need for store_artifacts on nightly builds
84+
85+
workflows:
86+
version: 2
87+
commit:
88+
jobs:
89+
- build
90+
nightly:
91+
triggers:
92+
- schedule:
93+
cron: "0 0 * * *"
94+
filters:
95+
branches:
96+
only:
97+
- master
98+
jobs:
99+
- build_nightly

Diff for: .gitignore

+104
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
build/
12+
develop-eggs/
13+
dist/
14+
downloads/
15+
eggs/
16+
.eggs/
17+
lib/
18+
lib64/
19+
parts/
20+
sdist/
21+
var/
22+
wheels/
23+
*.egg-info/
24+
.installed.cfg
25+
*.egg
26+
MANIFEST
27+
28+
# PyInstaller
29+
# Usually these files are written by a python script from a template
30+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
31+
*.manifest
32+
*.spec
33+
34+
# Installer logs
35+
pip-log.txt
36+
pip-delete-this-directory.txt
37+
38+
# Unit test / coverage reports
39+
htmlcov/
40+
.tox/
41+
.coverage
42+
.coverage.*
43+
.cache
44+
nosetests.xml
45+
coverage.xml
46+
*.cover
47+
.hypothesis/
48+
.pytest_cache/
49+
50+
# Translations
51+
*.mo
52+
*.pot
53+
54+
# Django stuff:
55+
*.log
56+
local_settings.py
57+
db.sqlite3
58+
59+
# Flask stuff:
60+
instance/
61+
.webassets-cache
62+
63+
# Scrapy stuff:
64+
.scrapy
65+
66+
# Sphinx documentation
67+
docs/_build/
68+
69+
# PyBuilder
70+
target/
71+
72+
# Jupyter Notebook
73+
.ipynb_checkpoints
74+
75+
# pyenv
76+
.python-version
77+
78+
# celery beat schedule file
79+
celerybeat-schedule
80+
81+
# SageMath parsed files
82+
*.sage.py
83+
84+
# Environments
85+
.env
86+
.venv
87+
env/
88+
venv/
89+
ENV/
90+
env.bak/
91+
venv.bak/
92+
93+
# Spyder project settings
94+
.spyderproject
95+
.spyproject
96+
97+
# Rope project settings
98+
.ropeproject
99+
100+
# mkdocs documentation
101+
/site
102+
103+
# mypy
104+
.mypy_cache/

Diff for: redisbloom/__init__.py

Whitespace-only changes.

0 commit comments

Comments
 (0)