Brandon Sandrowicz
20f62e828b
Fix Possible Typo
...
Looks like that was meant to be `config_key`. It works by accident because the function is defined in the same scope as the look that passes `config_key` to `apprunner`.
10 years ago
Markus Unterwaditzer
1577e1386e
Revert "Don't use threads in this test"
...
This reverts commit 78cd4161f0
.
10 years ago
Markus Unterwaditzer
78cd4161f0
Don't use threads in this test
...
I think test failures would've been ignored if there were some.
Fixes #1401
10 years ago
Chris Rebert
6d2c076a3b
make test_request_preprocessing_early_return more thorough
10 years ago
Markus Unterwaditzer
1158e22958
Fix test under Python 3
10 years ago
Markus Unterwaditzer
5fa76f6800
Add testcase for behavior described in #1338
10 years ago
Parkayun
33534bb4a9
Happy New Year 2015
10 years ago
Michael Hall
98b155c65d
Fixed #1288 : app.add_url_rule() should look for OPTIONS methods in a case-insensitive manner
10 years ago
Marc Abramowitz
d9402fc0c0
Make `jsonify` terminate responses with a newline
...
This came up in the context of
https://github.com/kennethreitz/httpbin/issues/168
10 years ago
Markus Unterwaditzer
bd232e5c82
PEP8
10 years ago
Gilman Callsen
d425279650
Improve compression by removing whitespace from separators when using jsonify() and JSONIFY_PRETTYPRINT_REGULAR is False.
...
Commit includes Changelog entry and two new tests in test_basic.py.
10 years ago
Paulo Bu
3f67fe94f1
Adds 2 tests for Flask.run method
10 years ago
Markus Unterwaditzer
a4931ff3a7
Kill class in test_basic
10 years ago
Markus Unterwaditzer
af4cb0ff2b
Remove flask superclass
10 years ago
Markus Unterwaditzer
af41dbe0c4
Remove useless classes
10 years ago
Markus Unterwaditzer
5da2c00419
Rewrite assertion methods
10 years ago
Markus Unterwaditzer
8fa5e32d9a
Tests pass now.
10 years ago
Markus Unterwaditzer
961db8ad72
Made tests recognizable
10 years ago
Markus Unterwaditzer
3550b26071
Move tests
10 years ago
Armin Ronacher
817b72d484
Removed deprecated module functionality
10 years ago
Armin Ronacher
84ad89ffa4
Always log now, even if debug is off.
10 years ago
Armin Ronacher
ddb5f9dc49
Fixed a broken test
11 years ago
Armin Ronacher
75f2af7a6a
Use a condition variable instead of sleeping
11 years ago
Alexis Svinartchouk
280d865960
fix issue #879 and add a test for it
...
Signed-off-by: Armin Ronacher <armin.ronacher@active-4.com>
11 years ago
Daniel Neuhäuser
52098e1e4f
Happy New Year 2014
11 years ago
Mikael Åhlén
dbc4096191
added a new test case with a Response instance and cleaned up the code
11 years ago
Mikael Åhlén
70f8b39c52
added a new behaviour for responses that enable the tuple to be in the form of (response, headers) and continiue to support the (response, status, headers) format.
11 years ago
Daniel Richman
3d67736e09
Check error handlers for specific classes first
...
This allows adding error handlers like this:
@app.errorhandler(werkzeug.exceptions.Forbidden)
And subclassing HTTPExceptions:
class ForbiddenBecauseReason(Forbidden): pass
@app.errorhandler(ForbiddenBecauseReason)
def error1(): return "Forbidden because reason", 403
@app.errorhandler(403)
def error2(): return "Forbidden", 403
... the idea being, that a flask extension might want to raise an
exception, with the default behaviour of creating a HTTP error page,
but still allowing the user to add a view/handler specific to that
exception (e.g., "Forbidden because you are not in the right group").
11 years ago
Markus Unterwaditzer
af5a0853bf
Fix #815
11 years ago
Armin Ronacher
3e4dbf93d9
Fixed a test that broke on 3.x
11 years ago
Armin Ronacher
d1d835c023
Added SESSION_REFRESH_EACH_REQUEST config option.
...
This also changes how sessions are being refreshed. With the new
behavior set-cookie is only emitted if the session is modified or if the
session is permanent. Permanent sessions can be set to not refresh
automatically through the SESSION_REFRESH_EACH_REQUEST config key.
This fixes #798 .
11 years ago
Serge S. Koval
44e39ab071
Fixed class-based views support
12 years ago
Armin Ronacher
58ad83f37c
Added support for bytes in sessions back
12 years ago
Armin Ronacher
c889fbc231
Changed interface for `flask.g`
...
This now makes it behave like it did before, it's just an object.
It did however gain ``__contains__`` and ``__iter__`` and I added
a ``get()`` method to fetch an attribute without raising an
error. This fixes #759 .
12 years ago
Armin Ronacher
93073489a0
Documented changes on the g object some more
12 years ago
Armin Ronacher
fd99abea57
Fixed too strict tests for cookie setting that broke on werkzeug changes
12 years ago
Armin Ronacher
56d3b74488
Added a test for non-ascii routing
12 years ago
Armin Ronacher
1b40b3b573
Fixed request context preservation and teardown handler interaction.
12 years ago
Armin Ronacher
90e3906d02
Fixed some test failures
12 years ago
Armin Ronacher
eb622fb34f
Fixed a whole bunch of resource warnings in the flask testsuite
12 years ago
Armin Ronacher
47572c5b40
Set the content length automatically before calling wrap_file
12 years ago
Thomas Waldmann
ac04bc7836
replace 1/0 by 1 // 0 to get rid of DeprecationWarning (and PEP8 issue)
12 years ago
Thomas Waldmann
f9e9e77464
fix data types in after_request test
...
TODO: why was that bug not causing / displaying an exception somehow?
should give a TypeError in py 3.3.
12 years ago
Daniel Neuhäuser
79ec3d81c1
Prevent UnboundLocalError in test_build_error_handler
12 years ago
Daniel Neuhäuser
a0801719f8
Remove six dependency
12 years ago
Daniel Neuhäuser
62e7275bdf
Use assert_false where appropriate
12 years ago
Daniel Neuhäuser
9f8a2075c7
Use assert_in where appropriate
12 years ago
Daniel Neuhäuser
239780be28
Use assert_true instead of assert_
...
assert_ is deprecated which causes annoying warnings
12 years ago
Daniel Neuhäuser
5b89355b1c
Response data is bytes
12 years ago
Markus Unterwaditzer
05f66ad735
Fix some literals
12 years ago