Commit graph

104 commits

Author SHA1 Message Date
David Lord
84e9ff3853 clean up js example 2018-04-12 12:17:14 -07:00
David Lord
a894586ba8 add javascript ajax example 2018-04-12 11:06:02 -07:00
David Lord
e29bd92c52 rewrite tutorial docs and example 2018-04-09 00:53:25 -07:00
David Lord
aa4db37a7f revert copyright year to project start
add copyright header to files
2018-02-08 12:43:30 -08:00
David Lord
ab317feebd fix windows failure to remove temp file 2018-01-05 12:36:01 -08:00
domandinho
17e795d6f5 Minor fix in flaskr example README 2017-11-09 22:52:24 +01:00
Arie Marie 'Thomas' Dalleis
f6751b5e26 Fix typos and formatting 2017-08-15 16:05:48 +02:00
David Lord
d590d6024d clean up secret key docs
consistent key across docs and examples
consistent key across tests, set in conftest
2017-06-28 07:58:06 -07:00
David Lord
4477a85ceb set example app names directly 2017-05-27 12:47:44 -07:00
David Lord
552fbf59b5 flaskr correct app name 2017-05-27 08:44:07 -07:00
Kenneth Reitz
551883bc04 i think this is how this works now 2017-05-25 18:01:52 -04:00
Kenneth Reitz
f27489679e Merge branch 'master' into improve-flaskr 2017-05-25 14:40:52 -07:00
bovarysme
34a921ca6e Fix a small oversight in the testing docs 2017-05-23 22:22:16 +02:00
David Lord
47717e5564 Merge pull request #2311 from bovarysme/use-yield-syntax
Use the yield syntax in pytest's fixtures
2017-05-23 12:00:34 -07:00
bovarysme
e94527717e Use the yield syntax in pytest's fixtures 2017-05-23 18:21:29 +02:00
Neil Grey
b7b9fdf778 For Issue #2286: Updating test_flaskr to use yield inside fixture 2017-05-22 18:22:08 -07:00
Kyle Lawlor
73e67d30d4 Add in a fixture utilizing app factory 2017-04-02 12:29:37 -04:00
Kyle Lawlor
b1b1d58aa6 Adds in blueprints and an application factory 2017-04-01 20:37:19 -04:00
Jeff Widman
2ad2aadb88 Migrate various docs links to https (#2180)
Also fixed a few outdated links
2017-02-11 10:43:11 +01:00
wgwz
750d01b30b Remove unneccessary arg in client fixture 2016-12-31 12:37:39 -05:00
wgwz
cc9b3c60da Moves largerapp into patterns dir and add test
- also adds this pattern into tox for testing
2016-12-31 12:08:25 -05:00
wgwz
055708866b Adds the largerapp from the docs as an example 2016-12-30 13:42:05 -05:00
Hopsken
755401d5dc Update README for minitwit (#2119)
add step 2 to run minitwit
2016-12-21 21:07:09 +01:00
Markus Unterwaditzer
0aa7ebd1e9 Fix import error 2016-11-15 11:58:44 +01:00
Markus Unterwaditzer
b506b7bfbf Merge branch '0.11-maintenance' 2016-10-30 14:35:15 +01:00
Kyle Lawlor
02cab299c3 Fixes import statement in flaskr (#2068)
- `from flaskr.flaskr import app` in flaskr/__init__.py
  causes an import error with Python 2
- The relative import now used works for py2 and py3
2016-10-30 14:34:49 +01:00
Hassam
bcd5432761 Fix #2051: Fix flaskr import in flaskr/__init__.py (#2052) 2016-10-08 20:34:56 +02:00
Markus Unterwaditzer
525e266822 Merge branch '0.11-maintenance' 2016-09-08 15:21:05 +02:00
Kyle Lawlor
8d501150d7 Better workflow for flaskr and other basic apps (#2000)
- adds `from flaskr import app` to top-level in flaskr module
- effect is that `export FLASK_APP=flaskr` works over the more verbose
  `export FLASK_APP=flaskr.flask`
- see the readme for how to run
- all tests are passing with `py.test` or `python setup.py test` (in
  venv)
2016-08-31 18:37:36 +02:00
Kyle Lawlor
d42e548f07 Update minitwit & improve testing for examples (#1954)
* Update minitwit & improve testing for examples

* Related to #1945
* Re-works minitwit to be installed and run as:

    pip install --editable .
    export FLASK_APP=minitwit.minitwit
    export FLASK_DEBUG=1
    flask initdb
    flask run

* added flaskr and minitwit to norecursedirs
  * tests not properly run when using pytest standards
  * see: http://stackoverflow.com/questions/38313171/configuring-pytest-with-installable-examples-in-a-project
* Both flaskr and minitwit now follow pytest standards.
* Tests can for them as `py.test` or `python setup.py test`

* Update minitwit readme

* updates the instructions for running

* Fixes for updating the minitwit example

- This reverts the changes to the *docs/* (I will file separate PR).
- Running the app is now: `export FLASK_APP=minitwit` & `flask run`
  (After installing the app)

* Remove unnecessary comma from flaskr/setup.py
2016-08-22 20:52:54 +02:00
ahmedakef
4800f05041 close <li> tag in lines (16,18) (#1951)
i noticed that <li> tag haven't closed in lines 15,18 
which is bad practice as if i put "some thing : <h1> some text </h1>" in the text-area  all the other articles become <h1> so big and color blue
2016-07-28 22:46:42 +02:00
David Lord
21cb0923cb persona is discontinued, remove example
closes #1947
2016-07-06 08:02:13 -07:00
Kyle Lawlor
d83d72b480 Address #1902: Converts example/flaskr to have a setup.py (#1945)
* Converts example/flaskr to have a setup.py

Makes the flaskr app easier to run, ex. workflow:
- pip install --editable .
- export FLASK_APP=flaskr.flaskr
- flask initdb
- flask run

Testing is also easier now:
- python setup.py test

* Fixed an import error in flaskr/tests

- the statement `import flaskr` caused errors in python3
- `from . import flaskr` fixes the issue in 2.7.11 and 3.5.1

* Better project structure and updates the docs

- Re-factors *flaskr*'s project structure a bit
- Updates docs to make sense with the new structure
  - Adds a new step about installing Flask apps with setuptools
  - Switches first-person style writing to second-person (reads better IMO)
  - Adds segments in *testing.rst* for running tests with setuptools

* Remove __init__.py from tests

- py.test recommends not using __init__.py

* Fix testing import errors
2016-07-05 17:30:59 -07:00
Armin Ronacher
4cb36cbafc Update docs to the new CLI patterns 2016-05-26 20:45:50 +02:00
Aayush Kasurde
c6ead5942e Added fix for issue 1529
Signed-off-by: Aayush Kasurde <aayush.kasurde@gmail.com>
2015-07-12 21:08:16 +05:30
Markus Unterwaditzer
5bfe6e6e94 Add readme to persona example
Fix #1310
2015-01-17 13:18:27 +01:00
Parkayun
e05771ff60 Happy New Year 2015 2015-01-02 11:35:00 +09:00
defuz
bc4916f89d docs: Don't touch markdown files 2014-11-05 08:40:57 +03:00
defuz
b5c9ad68dd docs: :file:app.py, :file:yourapp/templates 2014-11-05 06:45:22 +03:00
Petr Zemek
2593ae00cf Unify the uses of "urls" vs "URLs".
Use "URLs", which is more prevailing in the source code.
2014-10-27 11:36:23 +01:00
tay-k
cc5c633a30 fix filename of test files in README of examples 2014-09-18 18:21:36 +09:00
Markus Unterwaditzer
1c40e7ad49 Tests pass now. 2014-09-11 22:09:50 +02:00
Jeffrey D
4adccd4dfa Addressed issue #1134 2014-07-29 20:42:28 -05:00
Suraj Patil
f9eb5aa7a2 The example does not execute
With the inclusion of the app.run we now are able to execute the program, it would be great if we'd have even more detailed docs available for the examples
2014-07-03 18:19:09 +05:30
Armin Ronacher
081fe261be Fixed flask tests 2014-05-02 11:46:04 +01:00
Armin Ronacher
1043cf7d57 Updated the examples to be cli based 2014-04-29 01:48:31 +02:00
Armin Ronacher
b71f3f03bc Updated tutorial to the flask script 2014-04-28 15:18:27 +02:00
Kenneth Reitz
5873bb6c59 Merge pull request #889 from mattskone/master
Escaped 'text' keyword in column name.
2014-03-21 16:38:00 -04:00
Armin Ronacher
0dd3aa5f13 Switch away from /tmp for windows users 2014-02-08 22:07:13 +00:00
Tommaso Allevi
b81b040110 Remove unused import 2014-01-11 01:13:32 +01:00