Docker & Django: Pytest doesn't run
I'm running Docker to load my Django project locally. Pytest works perfectly without Docker, but since I am using Docker, running the command in my container bash brings back lot's of errors.
My docker-compose
version: '3'
services:
db:
image: postgres
ports:
- "5432:5432"
web:
build: .
env_file: .env
volumes:
- .:/code
ports:
- "8000:8000"
depends_on:
- db
container_name: local
Dockerfile
# Pull base image
FROM python:3
# Set environment varibles
ENV PYTHONUNBUFFERED 1
# Set work directory
RUN mkdir /code
WORKDIR /code
# Install dependencies
RUN pip install --upgrade pip
RUN pip install pipenv
COPY ./Pipfile /code/Pipfile
RUN pipenv install --deploy --system --skip-lock --dev
# Define ENTRYPOINT
COPY ./docker-entrypoint.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
# Copy project
COPY . /code/
My initial thought is that docker doesn't let pytest create the test database. Did you ever had issues with that and can tell me how to fix it?
Console log with failures >
python django docker docker-compose pytest
add a comment |
I'm running Docker to load my Django project locally. Pytest works perfectly without Docker, but since I am using Docker, running the command in my container bash brings back lot's of errors.
My docker-compose
version: '3'
services:
db:
image: postgres
ports:
- "5432:5432"
web:
build: .
env_file: .env
volumes:
- .:/code
ports:
- "8000:8000"
depends_on:
- db
container_name: local
Dockerfile
# Pull base image
FROM python:3
# Set environment varibles
ENV PYTHONUNBUFFERED 1
# Set work directory
RUN mkdir /code
WORKDIR /code
# Install dependencies
RUN pip install --upgrade pip
RUN pip install pipenv
COPY ./Pipfile /code/Pipfile
RUN pipenv install --deploy --system --skip-lock --dev
# Define ENTRYPOINT
COPY ./docker-entrypoint.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
# Copy project
COPY . /code/
My initial thought is that docker doesn't let pytest create the test database. Did you ever had issues with that and can tell me how to fix it?
Console log with failures >
python django docker docker-compose pytest
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
1
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a wordelf =
should presumably beself =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For exampletest_utils.py
has twoE
, so you can start there.
– Håken Lid
Nov 11 '18 at 19:45
Thank you for the link. I now brought it down to one testtests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.
– Joey Coder
Nov 12 '18 at 7:29
add a comment |
I'm running Docker to load my Django project locally. Pytest works perfectly without Docker, but since I am using Docker, running the command in my container bash brings back lot's of errors.
My docker-compose
version: '3'
services:
db:
image: postgres
ports:
- "5432:5432"
web:
build: .
env_file: .env
volumes:
- .:/code
ports:
- "8000:8000"
depends_on:
- db
container_name: local
Dockerfile
# Pull base image
FROM python:3
# Set environment varibles
ENV PYTHONUNBUFFERED 1
# Set work directory
RUN mkdir /code
WORKDIR /code
# Install dependencies
RUN pip install --upgrade pip
RUN pip install pipenv
COPY ./Pipfile /code/Pipfile
RUN pipenv install --deploy --system --skip-lock --dev
# Define ENTRYPOINT
COPY ./docker-entrypoint.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
# Copy project
COPY . /code/
My initial thought is that docker doesn't let pytest create the test database. Did you ever had issues with that and can tell me how to fix it?
Console log with failures >
python django docker docker-compose pytest
I'm running Docker to load my Django project locally. Pytest works perfectly without Docker, but since I am using Docker, running the command in my container bash brings back lot's of errors.
My docker-compose
version: '3'
services:
db:
image: postgres
ports:
- "5432:5432"
web:
build: .
env_file: .env
volumes:
- .:/code
ports:
- "8000:8000"
depends_on:
- db
container_name: local
Dockerfile
# Pull base image
FROM python:3
# Set environment varibles
ENV PYTHONUNBUFFERED 1
# Set work directory
RUN mkdir /code
WORKDIR /code
# Install dependencies
RUN pip install --upgrade pip
RUN pip install pipenv
COPY ./Pipfile /code/Pipfile
RUN pipenv install --deploy --system --skip-lock --dev
# Define ENTRYPOINT
COPY ./docker-entrypoint.sh /docker-entrypoint.sh
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
# Copy project
COPY . /code/
My initial thought is that docker doesn't let pytest create the test database. Did you ever had issues with that and can tell me how to fix it?
Console log with failures >
python django docker docker-compose pytest
python django docker docker-compose pytest
edited Nov 12 '18 at 7:27
asked Nov 11 '18 at 19:06
Joey Coder
2288
2288
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
1
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a wordelf =
should presumably beself =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For exampletest_utils.py
has twoE
, so you can start there.
– Håken Lid
Nov 11 '18 at 19:45
Thank you for the link. I now brought it down to one testtests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.
– Joey Coder
Nov 12 '18 at 7:29
add a comment |
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
1
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a wordelf =
should presumably beself =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For exampletest_utils.py
has twoE
, so you can start there.
– Håken Lid
Nov 11 '18 at 19:45
Thank you for the link. I now brought it down to one testtests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.
– Joey Coder
Nov 12 '18 at 7:29
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
1
1
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a word
elf =
should presumably be self =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For example test_utils.py
has two E
, so you can start there.– Håken Lid
Nov 11 '18 at 19:45
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a word
elf =
should presumably be self =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For example test_utils.py
has two E
, so you can start there.– Håken Lid
Nov 11 '18 at 19:45
Thank you for the link. I now brought it down to one test
tests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.– Joey Coder
Nov 12 '18 at 7:29
Thank you for the link. I now brought it down to one test
tests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.– Joey Coder
Nov 12 '18 at 7:29
add a comment |
2 Answers
2
active
oldest
votes
You have omitted the most important part of the exceptions, but based on the errors I'm guessing you haven't run your database migrations due to which the Postgres database does not have the necessary tables for the tests.
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition ofself.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
add a comment |
What container image are you using to run the python code? (it seems to be missing from your compose file).
Based on the deprecation warnings it seems your calling a method that does not exist (i.e. callable is None). Are all dependencies installed in your container?
Additionally, do you have a DockerFile available that installs all dependencies?
Something like:
# Use an official Python runtime as a parent image
FROM python:3.6-slim
# Set the working directory to /app
WORKDIR /app
# copy requirements.txt
ADD ./requirements.txt /app/requirements.txt
# Install any needed packages specified in requirements.txt
RUN pip install --trusted-host pypi.python.org -r requirements.txt
# Copy the current directory contents into the container at /app
ADD . /app
And then in the compose file you could build it like this:
web:
build:
context: ./
dockerfile: /path/to/Dockerfile
command: cd /app/path/to/where/pytest/should/be/executed && pytest
Note that this answer does not rely on a host-mounted volume, but rather copies your code into the container, and creates an image that can be used everywhere.
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53252180%2fdocker-django-pytest-doesnt-run%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
You have omitted the most important part of the exceptions, but based on the errors I'm guessing you haven't run your database migrations due to which the Postgres database does not have the necessary tables for the tests.
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition ofself.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
add a comment |
You have omitted the most important part of the exceptions, but based on the errors I'm guessing you haven't run your database migrations due to which the Postgres database does not have the necessary tables for the tests.
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition ofself.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
add a comment |
You have omitted the most important part of the exceptions, but based on the errors I'm guessing you haven't run your database migrations due to which the Postgres database does not have the necessary tables for the tests.
You have omitted the most important part of the exceptions, but based on the errors I'm guessing you haven't run your database migrations due to which the Postgres database does not have the necessary tables for the tests.
answered Nov 11 '18 at 21:35
Uku Loskit
30.1k86879
30.1k86879
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition ofself.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
add a comment |
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition ofself.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
Hi Uku Loskit, I changed my post and tested one .py file that fails. I inserted the whole console log here: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition of
self.user
– Uku Loskit
Nov 12 '18 at 8:20
based on the error, it looks like you are trying to insert an e-mail into an id field. So the error seems to be on the code level rather than related at docker. it would useful to see the definition of
self.user
– Uku Loskit
Nov 12 '18 at 8:20
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
It's really weird. Running it on another computer with pipenv as Dev environment pytest runs smooth.
– Joey Coder
Nov 12 '18 at 11:28
add a comment |
What container image are you using to run the python code? (it seems to be missing from your compose file).
Based on the deprecation warnings it seems your calling a method that does not exist (i.e. callable is None). Are all dependencies installed in your container?
Additionally, do you have a DockerFile available that installs all dependencies?
Something like:
# Use an official Python runtime as a parent image
FROM python:3.6-slim
# Set the working directory to /app
WORKDIR /app
# copy requirements.txt
ADD ./requirements.txt /app/requirements.txt
# Install any needed packages specified in requirements.txt
RUN pip install --trusted-host pypi.python.org -r requirements.txt
# Copy the current directory contents into the container at /app
ADD . /app
And then in the compose file you could build it like this:
web:
build:
context: ./
dockerfile: /path/to/Dockerfile
command: cd /app/path/to/where/pytest/should/be/executed && pytest
Note that this answer does not rely on a host-mounted volume, but rather copies your code into the container, and creates an image that can be used everywhere.
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
add a comment |
What container image are you using to run the python code? (it seems to be missing from your compose file).
Based on the deprecation warnings it seems your calling a method that does not exist (i.e. callable is None). Are all dependencies installed in your container?
Additionally, do you have a DockerFile available that installs all dependencies?
Something like:
# Use an official Python runtime as a parent image
FROM python:3.6-slim
# Set the working directory to /app
WORKDIR /app
# copy requirements.txt
ADD ./requirements.txt /app/requirements.txt
# Install any needed packages specified in requirements.txt
RUN pip install --trusted-host pypi.python.org -r requirements.txt
# Copy the current directory contents into the container at /app
ADD . /app
And then in the compose file you could build it like this:
web:
build:
context: ./
dockerfile: /path/to/Dockerfile
command: cd /app/path/to/where/pytest/should/be/executed && pytest
Note that this answer does not rely on a host-mounted volume, but rather copies your code into the container, and creates an image that can be used everywhere.
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
add a comment |
What container image are you using to run the python code? (it seems to be missing from your compose file).
Based on the deprecation warnings it seems your calling a method that does not exist (i.e. callable is None). Are all dependencies installed in your container?
Additionally, do you have a DockerFile available that installs all dependencies?
Something like:
# Use an official Python runtime as a parent image
FROM python:3.6-slim
# Set the working directory to /app
WORKDIR /app
# copy requirements.txt
ADD ./requirements.txt /app/requirements.txt
# Install any needed packages specified in requirements.txt
RUN pip install --trusted-host pypi.python.org -r requirements.txt
# Copy the current directory contents into the container at /app
ADD . /app
And then in the compose file you could build it like this:
web:
build:
context: ./
dockerfile: /path/to/Dockerfile
command: cd /app/path/to/where/pytest/should/be/executed && pytest
Note that this answer does not rely on a host-mounted volume, but rather copies your code into the container, and creates an image that can be used everywhere.
What container image are you using to run the python code? (it seems to be missing from your compose file).
Based on the deprecation warnings it seems your calling a method that does not exist (i.e. callable is None). Are all dependencies installed in your container?
Additionally, do you have a DockerFile available that installs all dependencies?
Something like:
# Use an official Python runtime as a parent image
FROM python:3.6-slim
# Set the working directory to /app
WORKDIR /app
# copy requirements.txt
ADD ./requirements.txt /app/requirements.txt
# Install any needed packages specified in requirements.txt
RUN pip install --trusted-host pypi.python.org -r requirements.txt
# Copy the current directory contents into the container at /app
ADD . /app
And then in the compose file you could build it like this:
web:
build:
context: ./
dockerfile: /path/to/Dockerfile
command: cd /app/path/to/where/pytest/should/be/executed && pytest
Note that this answer does not rely on a host-mounted volume, but rather copies your code into the container, and creates an image that can be used everywhere.
answered Nov 11 '18 at 19:33
benvdh
8016
8016
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
add a comment |
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Hi benvdh, I added my Dockerfile
– Joey Coder
Nov 11 '18 at 19:43
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thanks. It seems ok. You might try something like pastebin.com to post the full stacktrace and add the link to this question. At the moment it's hard to see the real error in what you've posted.
– benvdh
Nov 11 '18 at 19:53
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
Thank you, I have done that, good suggestion: pastebin.com/vX5eR16y
– Joey Coder
Nov 12 '18 at 7:30
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53252180%2fdocker-django-pytest-doesnt-run%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You have only included a small part of the pytest output. There's 3 errors and 308 failing tests. At least include the tracebacks for all the errors.
– Håken Lid
Nov 11 '18 at 19:40
I tried, but SO doesn't allow that much text. So I had to cut it.
– Joey Coder
Nov 11 '18 at 19:42
1
So create a Minimal, Complete, and Verifiable example. The error seems to be cut in the middle of a word
elf =
should presumably beself =
You didn't even include the type of exception. It's possible to have pytest just run a few tests at a time. Then you should get a shorter output. For exampletest_utils.py
has twoE
, so you can start there.– Håken Lid
Nov 11 '18 at 19:45
Thank you for the link. I now brought it down to one test
tests/checkin/test_views.py
and as it was still too long, I added it to pastebin and inserted the link instead.– Joey Coder
Nov 12 '18 at 7:29