Creating mock objects is a useful technique that allows you to concentrate on one part of the application without having to worry about other parts of the system that don't exist yet. I want to design the home page of my application, and I don't want the fact that I don't have a ...
This process not only helps ensure correctness of the code -- but also helps to indirectly evolve the design and architecture of the project at hand.TDD usually follows the "Red-Green-Refactor" cycle, as shown in the image above:Write a test Run the test (it should fail) Write just ...
Application design is an essential aspect of software development. An unplanned application design results in insurmountable technical debt. Therefore, whenever we want to scale our application, then it is okay to try out time tested design patterns. Flask community has many such examples that can i...
You can use the CSS language to style the application and make it more appealing using your own design. However, if you’re not a web designer, or if you aren’t familiar with CSS, then you can use theBootstrap toolkit, which provides easy-to-use components for styling your application....
However not every application needs a SQL database. As your codebase grows, you are free to make the design decisions appropriate for your project. Flask will continue to provide a very simple glue layer to the best that Python has to offer. You can implement advanced patterns in SQLAlchemy...
Use the Flask Web Project template to create an app with multiple pages and responsive design (step 4). Use the Polls Flask Web Project template to create a polling app that uses various storage options (Azure storage, MongoDB, or memory). ...
Let's expand our database to store posts, so that we can see relationships in action. For this we go back to our database design tool and create apoststable: Ourpoststable will have the requiredid, thebodyof the post and atimestamp. Not much new there. But theuser_idfield deserves ...
Add the following styles tostatic/site.css, below the existing "message" style, and save the file. Note that this walkthrough doesn't attempt to demonstrate responsive design; these styles simply generate a reasonably interesting result.
Use the Flask Web Project template to create an app with multiple pages and responsive design (step 4). Use the Polls Flask Web Project template to create a polling app that uses various storage options (Azure storage, MongoDB, or memory). Over...
This process not only helps ensure correctness of the code -- but also helps to indirectly evolve the design and architecture of the project at hand.TDD usually follows the "Red-Green-Refactor" cycle, as shown in the image above:Write a test Run the test (it should fail) Write just ...