These are some common tasks to be done as a part of developing
and maintaining repo2docker. If you'd like more guidance for how
to do these things, reach out in the [JupyterHub Gitter channel](https://gitter.im/jupyterhub/jupyterhub).
## Running tests
We have a lot of tests for various cases supported by repo2docker in the `tests/`
subdirectory. If you fix a bug or add new functionality consider adding a new
test to prevent the bug from coming back. These use
[py.test](https://docs.pytest.org/).
You can run all the tests with:
```bash
py.test -s tests/*
```
If you want to run a specific test, you can do so with:
```bash
py.test -s tests/<path-to-test>
```
## Update and Freeze BuildPack Dependencies
This section covers the process by which repo2docker defines and updates the
dependencies that are installed by default for several buildpacks.
For both the `conda` and `virtualenv` (`pip`) base environments in the **Conda BuildPack** and **Python BuildPack**,
we install specific pinned versions of all dependencies. We explicitly list the dependencies
we want, then *freeze* them at commit time to explicitly list all the
transitive dependencies at current versions. This way, we know that
all dependencies will have the exact same version installed at all times.
To update one of the dependencies shared across all `repo2docker` builds, you
must follow these steps (with more detailed information in the sections below):
1. Make sure you have [Docker](https://www.docker.com/) running on your computer
2. Bump the version numbers of the dependencies you want to update in the `conda` environment ([link](https://github.com/jupyter/repo2docker/blob/master/CONTRIBUTING.md#conda-dependencies))
3. Make a pull request with your changes ([link](https://github.com/jupyter/repo2docker/blob/master/CONTRIBUTING.md#make-a-pull-request))
See the subsections below for more detailed instructions.
### Conda dependencies
1. There are two files related to conda dependencies. Edit as needed.
-`repo2docker/buildpacks/conda/environment.yml`
Contains list of packages to install in Python3 conda environments,
which are the default. **This is where all Notebook versions &
notebook extensions (such as JupyterLab / nteract) go**.