Hi man,
How about pk you expect to test by declare in test.py with '/post/264, so
!= 200 in result!?
On Sun, Feb 2, 2020, 22:05 Body Abdo wrote:
> Dear all
>
> I can't do the test -error is
> self.assertEqual(response.status_code, 200)
> AssertionError: 404 != 20
Dear all
I can't do the test -error is
self.assertEqual(response.status_code, 200)
AssertionError: 404 != 200
My code is
views.py
class DetailPageView(DetailView):
model = Series
template_name='/var/www/project/tapelss/movies/archive/templates/archive/detail.html'
ur
Hi Joel,
The fact that you are using Django 2.2 has nothing to do with if f strings
are supported. f-strings are a part of the python language. You need to
have at least version 3.6 installed to be able to use f-strings. Check your
python version by writing : python --version in a command shell. I
Why did you say that? I'm using django 2.2 and f strings are indeed supported.
Sincerely yours,
Joel G Mathew
On Sun, 21 Oct 2018 at 18:05, Motaz Hejaze wrote:
>
> f'{}' is not supported
>
> On Sun, Oct 21, 2018 at 2:29 PM Joel wrote:
>>
>> What is your version of python? f strings were intro
f'{}' is not supported
On Sun, Oct 21, 2018 at 2:29 PM Joel wrote:
> What is your version of python? f strings were introduced in 3.6
>
> On Sun, 21 Oct, 2018, 9:54 AM Tim Vogt (Tim Vogt),
> wrote:
>
>> I try to make a test with has an error
>> any suggestions?
>> tim
>>
>>
>> expected_auth
What is your version of python? f strings were introduced in 3.6
On Sun, 21 Oct, 2018, 9:54 AM Tim Vogt (Tim Vogt),
wrote:
> I try to make a test with has an error
> any suggestions?
> tim
>
>
> expected_author = f'{post.author}
> ^
> SyntaxError: EOL whil
He's using literal string interpolation.
Read: https://www.python.org/dev/peps/pep-0498/
On Sun, 21 Oct, 2018, 5:49 PM Tommaso Bellini,
wrote:
> What does mean 'f' ? It is not imported or instanced..what is it?
>
> Il dom 21 ott 2018, 06:24 Tim Vogt (Tim Vogt) ha
> scritto:
>
>> I try to make a
What does mean 'f' ? It is not imported or instanced..what is it?
Il dom 21 ott 2018, 06:24 Tim Vogt (Tim Vogt) ha
scritto:
> I try to make a test with has an error
> any suggestions?
> tim
>
>
> expected_author = f'{post.author}
> ^
> SyntaxError: EOL whi
I try to make a test with has an error
any suggestions?
tim
expected_author = f'{post.author}
^
SyntaxError: EOL while scanning string literal
--
Ran 1 test in 0.000s
FAILED (errors=1)
D
On Feb 13, 11:09 am, xina towner wrote:
> Hello, I still get this error:
> The problem es the order that django creates the tables in the database.
> Can I change this?
Are you sure the problem is not that importing the tests will generate
a query? The offending place seems to be:
> from qu
olando Espinoza La Fuente
wrote:
> On Tue, Mar 23, 2010 at 6:38 PM, John wrote:
> > I have encountered a Unit Test error while using a reverse url lookup
> > for i18n. All is running fine in the development environment. Issues
> > only occur during testing. It appears to possibly b
On Tue, Mar 23, 2010 at 6:38 PM, John wrote:
> I have encountered a Unit Test error while using a reverse url lookup
> for i18n. All is running fine in the development environment. Issues
> only occur during testing. It appears to possibly be an issue with
> shared contexts between
I have encountered a Unit Test error while using a reverse url lookup
for i18n. All is running fine in the development environment. Issues
only occur during testing. It appears to possibly be an issue with
shared contexts between contrib.auth and views.i18n.
Template Code
Unit Test
13 matches
Mail list logo