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

fixtures working #42

Merged
merged 2 commits into from
Aug 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 22 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,17 @@ Create the database and apply any necessary migrations:
python manage.py migrate
```

Next, seed your database with some data:

```
python manage.py loaddata fixtures.json
```

Once you've seeded the database, you will be able to log in with
either a staff account, student account, or teacher account, with usernames
'staff_user', 'student_user', and teacher_user, respectively. All three account
passwords are 'topsecret123'

Finally run the application on your local machine with:

```
Expand All @@ -52,8 +63,6 @@ Navigate in your browser to:
localhost:8000/
```

And Bob's your uncle.

## Running the tests

Your requirements.txt file has installed the `coverage` package for you, which provides a nice coverage report for all the tests.
Expand Down Expand Up @@ -124,6 +133,17 @@ Azure Storage server accessible at
docker-compose up
```

To seed your database with some data:

```
docker-compose run web python manage.py loaddata fixtures.json
```

Once you've seeded the database, you will be able to log in with
either a staff account, student account, or teacher account, with usernames
'staff_user', 'student_user', and teacher_user, respectively. All three account
passwords are 'topsecret123'

To start over with a fresh environment:

```bash
Expand Down
2 changes: 2 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ services:
- POSTGRES_DB=mbdb
volumes:
- pgdata:/var/lib/postgresql/data
ports:
- "5432:5432"
azurite:
image: mcr.microsoft.com/azure-storage/azurite
ports:
Expand Down
Loading