SD&D
Team Caffiends
Project Construction Deliverables
Version 1.3
Prepared by:
Jesse Herrmann1, Jeremy Betz2, Simon Sarris3, Sam Gruskin3,
Grace DiCiniti3
1
Electrical, Computer, and Systems Engineering
2
Mechanical Engineering
3
Computer Science
Rensselaer Polytechnic Institute, Troy, NY 12180, USA
Table of Contents
1. Executive Summary ............................................................................................................................... 3
2. Beta Release .......................................................................................................................................... 4
a. Requirements .................................................................................................................................... 4
b. Deployment....................................................................................................................................... 5
c. Sample Layout ................................................................................................................................... 6
d. Sequence Diagrams........................................................................................................................... 7
e. Static Class Diagram .......................................................................................................................... 9
f. Design Pattern and Best Practice .................................................................................................... 10
g. Source Code Location ..................................................................................................................... 10
3. Testing and Quality Assurance ............................................................................................................ 11
a. Test Plan .......................................................................................................................................... 11
b. Test Case Specification.................................................................................................................... 13
c. Preliminary Test Results .................................................................................................................. 14
4. Future Direction .................................................................................................................................. 16
a. Supplemental Requirements .......................................................................................................... 16
5. Best Practices ...................................................................................................................................... 17
6. References .......................................................................................................................................... 18
7. Sample Quality Assurance Procedure ................................................................................................. 19
9. Quality Assurance Trial Results ........................................................................................................... 20
10. Code Review........................................................................................................................................ 22
1. Executive Summary
Within the next five years, cafecafecafe.com will become the premier caffeinated beverage
review site on the Web by gathering a solid base of reputable user and staff reviews of cafe
locations and products.
We believe an attractive, clean layout and simple user mechanics will enable users to easily
create reviews, keep track of the brands and places they've tried, and share that information
with their friends to make our site into a useful community.
Users will be able to easily add reviews and search reviews suited to their tastes, and
discover new drinks they have never heard of before. Reviews will culminate into scores for
brands that have multiple products. Later, cafe reviews will be added into a similar review
system.
The website needs a broad user-base if it is to function well. One of the risks is that it may
take some time (possibly more than a year) in order to achieve a large population. Thankfully,
bandwidth costs will stay low until the site is actually popular, so the risk of great money loss
(after it is built) isn't too severe.
As with any review site, there is the risk of perceived bias and any affiliations or
sponsorship from beverage companies themselves must come long after the site's reputation is
established.
2. Beta Release
a. Requirements
Functionality
Users can register for the site and be placed within a database for future references.
Users can login using information sourced from the registration database and interact
with site content.
Users can view existing reviews and other content already stored within their respective
databases and represented on the site.
o Can be done without registering.
o Capability to display content based upon prioritization of attributed factors.
Date added, type, caffeine level, rating, etc.
Users can submit new beverages, brands, and cafes that are not already stored in the
database.
Users can place reviews for stored beverages, brands, and cafes.
o Comments and rating.
Users can view products as correlated to a particular brand or type of beverage.
Usability/Supportability
Site will operate as intended over majority of browser environments.
o Chrome, Firefox, IE7-8, Safari (not IE6)
Site will contain search function for simple navigation of content.
o Also provide list of all content for browsing purposes.
User can set various attributes regarding their profile for personalization.
o Profile text, avatar, location, email, etc.
User will be able to view their submitted reviews from profile.
Site will provide simple templates when prompted for the addition of user-generated
content.
Reliability/Performance
Site will be implementable in a stable hosting environment able to bear peak traffic.
Design/Implementation
Regional database will handle persistence.
Database will be MySQL.
Site will follow the Django framework.
Site will be scripted using Python.
o Python best practices will be representative of our own.
b. Deployment
c. Sample Layout
Figure 1 : Page Header
(Figure 1) Sample page header for site
Links to : Products, Contact, About, Search Function, Home, Login
o “Reviews” leads to a general directory of product links that in turn lead
to a product page with statistics and other attributes.
Clicking icon will link to main page
Search will look provide matches in Products, Brands, Cafes
When logged in, Login will be replaced with link to User profile.
Figure 2 : Product Page
(Figure 2) Sample page for product information
Allows user to submit review with rating and comment if logged in.
Will display average score and any submitted reviews.
d. Sequence Diagrams
Figure 3 : User Submit Review
Satisfies the requirement set forth by the functionality aspect of permitting the user to submit a
review for a brand, café, or product. This review will contain separate attributes for rating and
commentary, both to be entered into a server-supplied, standardized template.
Figure 4 : User Create Product
Satisfies the requirement set forth by functionality aspect of permitting the user to submit a
new product when their desired content does not exist within the database. The product will
contain a variable amount of attributes ranging from the mandatory (name, type, brand) to the
optional (picture, caffeine content, price) to be entered into a server-supplied, standardized
template. Following submission, the proposed product page will be displayed to the user for
final authorization.
e. Static Class Diagram
Café attributed to specific User (by location)
Review attributed to specific User (by submitter)
Review attributed to specific Product (by new review submission correlation)
Brand attributed to specific Product (by new product submission correlation)
Product attributed to specific Brand (by new product submission correlation)
f. Design Pattern and Best Practice
We will adhere to the Python Enhancement Proposal design practice as set forth by the
Python maintainers.
We will design all code around the Model View Controller design pattern.
g. Source Code Location
http://caffiends.googlecode.com/files/caffiends-beta.zip
3. Testing and Quality Assurance
a. Test Plan
Strategy
As our project emphasizes the applicability of the final product to a legitimate user
environment, it would be practical to approach quality assurance as if the site were in
full implementation. The coders may overlook a certain issue or shortcoming while
designing and producing portions of the site as often happens in full release products.
Our beta release testing centered upon uninvolved individuals running through the
various processes and services that the site was required to have by our own guidelines.
One member of our team that was relatively isolated from the design and coding of the
beta release was provided a copy of the current iteration and the list of requirements in
the second section of this report. They ran through:
o Registering a new account.
With and without valid parameters.
o Logging in to their account.
With and without valid parameters.
o Navigating pages through the header.
o Submitting a new product, brand, and café.
Pre-existing and non-represented examples of each.
o Submitting a review of a product.
o Searching for a product, brand, or café.
List and actual search of each.
o Modifying their user profile to their liking.
Quality Goals
We will consider the product a successful release when it fulfills the requirements set
forth by group consensus with no observable bugs after several iterations of the testing
strategy. At this point we would further refine the interface while exploring future
additions to the feature set that were not included in the beta release.
Schedule
{BEGIN: (3/25)} Project construction - Phase 1 {END: (4/29)}
Code should be complete for beverage/category reviewing
Test and benchmark database
Storyboard a front-end site using HTML, CSS, PHP, etc
UC1, UC2, UC4, UC5: Design (3/25-3/27), Development (3/27-4/6), Testing (4/6-
4/8)
UC7, UC10: Design (3/25-3/27), Development (3/27-4/6), Testing (4/6-4/8)
{BEGIN: (4/29)} Project construction - Phase 2 {END: (5/4)}
More testing
Coding and refinement of the site GUI
Enable extra features time? such as guides, mapping location, private
messaging, favorites (UC3, UC6, UC7, UC8, UC9, UC11)
UC3, UC6, UC7, UC8, UC9, UC11: Design (3/25-3/29), Development (3/29-4/5),
Testing (4/5-4/8)
{BEGIN: (5/4)} Project transition and finalization {END: (5/6)}
Final testing
Preparation for presentation
Figure 5 : Gantt Chart
Resources
When we began the project there was a relative lack of knowledge and experience in
the skills necessary for the fulfillment of our initial requirements. The reference section
of the paper is a complete listing of all resources used up to and including the beta
release.
In terms of testing, all staff and technology used has been sourced from within the
team, with all assigned tasks and requisitioned hardware listed in the section below.
Staff
o Coding
Backend – Simon, Grace
Frontend – Sam
Integration – Jeremy
o Quality Assurance
Testing – Jesse
o Documentation
Design Reports – Jesse
Presentation – Jesse, Jeremy
b. Test Case Specification
All testing will be done in a circular manner, flowing from one requirement into the next as a
normal user would do when approaching our site. Navigation will be done primarily through the
header while content addition will be via a server-provided form. The tester is given a list of
tasks to accomplish without any exact methodology so as to allow a measure of usability testing
beyond the simple requirements.
Register a new account.
o Choose credentials of your choice initially, but try to test as many possible
combinations of characters (alphanumeric or otherwise) with varying lengths.
Login to your account.
o Use chosen credentials to login; also try incorrect password and case-sensitivity.
Navigate to each page through the header.
Submit a new product and brand.
o Fabricate a new entry using the forms provided upon request to the site. Try
combinations of missing or invalid parameter fields, as well as submitting an
entry that already exists.
Submit a review.
o Navigate to a product and fabricate a new entry using the forms provided upon
request to the site. Try combinations of missing or invalid parameter fields.
Search for a product, brand, and café.
o Initially enter request in header search bar, once at the page listing possible
results select the proper one.
Modify your user profile.
o Enter your profile from the header and change the entries to your preference.
Try combinations of missing or invalid parameter fields.
c. Preliminary Test Results
Name
Email
OS
Browser
Choose rating based on ease of use, proper display,
and add commentary (higher is better). 1 2 3 4 5
Register a new account.
Comments :
Login to your account.
Comments :
Navigate to each page.
Comments :
Submit a new product and brand.
Comments :
Submit a review.
Comments :
Search for a product, brand, and café.
Comments :
Modify your user profile.
Comments :
Table 1 : Quality Assurance Questionnaire
All of the listed requirements have been met to at least some extent and are addressed in a cogent,
fully-usable manner within the site. As the site is still under construction there are several issues to be
addressed in the second phase and afterward concerning several bugs and a general crudeness of design
in the user interface. Though the most direct route toward achieving each of the objectives is functional,
I encountered most problems when trying to find them and they were easily fixable once discovered.
This is to be expected in a beta version and online implementation for a wider release will undoubtedly
make such bugs easier to find en masse.
Due to the early stage of development in a usable release there are a laundry list of bugs centering
mostly upon authentication and page addressing. The following are a select few that I have found:
Entering unidentified URL results in a page break rather than a 404 or redirect.
If user not logged in and attempts to submit review the site will break.
Long text fields in reviews causes wrapping issues.
CMS and non-CMS implemented pages have logo and navigation bar in inconsistent positions.
These issues and all future bugs that we find will be enumerated on the Issue/Bug tracker located
within our Google Code group.
4. Future Direction
As we intend to continually operate and improve the project even following the second phase of
construction it is essential to detail a roadmap for further development. Now that there is a stable
foundation encompassing core services that the site is marketed upon, a much more modular,
piece-by-piece approach is possible. In addition to new features there will be further refinement of
existing portions of the design in all areas of the supplemental specifications.
a. Supplemental Requirements
Functionality
User can review existing Cafés.
o Can also associate Products and Brands.
User can search cafés by proximity and other attributes.
User can have friends, favorites, groups, etc.
User can sort content by various attributes.
Usability/Supportability
Site will operate as intended over even legacy browsers.
o Retired versions of IE, Firefox, and Chrome
Design/Implementation
Implemented as a dot com accessible over Internet.
5. Best Practices
Project Site/Wiki
o Inception : http://code.google.com/p/caffiends/wiki/Inception
o Elaboration : http://code.google.com/p/caffiends/wiki/Elaboration
Code Repository
o Google Code : http://code.google.com/p/caffiends/source/browse/
Documented Coding Standards
o Python Enhancement Proposals : http://www.python.org/dev/peps/
PEP8 – Maximum Line Length
PEP8 – Inline Commenting
PEP8 – Class Naming Conventions
Bug Tracking System
o Google Code Issues : http://code.google.com/p/caffiends/issues/list
Third Party Components
o Django-Python : http://python.org/ftp/python/2.6.5/python-2.6.5.msi
o Django CMS : http://github.com/digi604/django-cms-2.0/zipball/2.0.2
o Mercurial : http://bitbucket.org/tortoisehg/stable/wiki/download
o Boilerplate Modules :
Reviews : http://pypi.python.org/pypi/django-reviews/0.2.1
Registration : http://bitbucket.org/ubernostrum/django-
registration/downloads
Design Patterns
o Model View Controller
Django Conventions : Models.py, views.py, Object Classes
6. References
Foundation, D. S. (n.d.). http://docs.djangoproject.com/en/1.1/intro/tutorial01/. Retrieved from Django
Tutorial.
Spolsky, J. (n.d.). http://hginit.com/. Retrieved from Mercurial Tutorial.
Links in Best Practices section contain much of the documentation we learned from.
7. Sample Quality Assurance Procedure
1. Navigate to “localhost:8000” in a browser window.
2. Click “Register.”
3. Follow the prompt to register a new account.
4. Check your selected email inbox for the authorization message and follow the link.
5. Click “Login” and enter your credentials.
6. Attempt to browse the site by clicking links within the page header.
7. Click “Product” link and then click either
a. Brand: to browse by them.
b. Product: to browse by them.
c. Add New: to add a new product or review.
8. Follow a link to a product page, attempt to submit a review.
Future implementations will require the addition of steps for searching, user profile, location
browsing, editing of comments, etc.
9. Quality Assurance Trial Results
Name Jesse (4/22/10)
Email herrmj@rpi.edu
OS Windows 7
Browser Google Chrome
Choose rating based on ease of use, proper display,
and add commentary (higher is better). 1 2 3 4 5
Register a new account. x
Comments : Needs to be clearer, can register multiple accounts to a single email
Login to your account. x
Comments : Works fine, including authorization email. Include prompts at top of page and stay logged in options
Navigate to each page. x
Comments : Navigation failure for many missing pages, wrong URL kills site
Submit a new product and brand. x
Comments : No functionality outside administration access
Submit a review. x
Comments : Limited functionality outside administration access, can’t calculate ratings, fails to align properly in CSS
Search for a product, brand, and café. x
Comments : No functionality
Modify your user profile. x
Comments : No functionality
Name Jesse (4/29/10)
Email herrmj@rpi.edu
OS Windows 7
Browser Google Chrome
Choose rating based on ease of use, proper display,
and add commentary (higher is better). 1 2 3 4 5
Register a new account. X
Comments : Needs to be clearer, can register multiple accounts to a single email
Login to your account. X
Comments : Works fine, including authorization email. Include prompts at top of page and stay logged in options
Navigate to each page. X
Comments : Navigation failure for many missing pages, wrong URL kills site, more logical flow than last test
Submit a new product and brand. X
Comments : Can now add product and brand administratively
Submit a review. X
Comments : Fails to align properly in CSS, adding review without being logged in kills site
Search for a product, brand, and café. X
Comments : Fully functional in administrative panel
Modify your user profile. X
Comments : Fully functional in administrative panel
10. Code Review
Our team conducted a peer review with cartoons.us. Their code had a few errors which they
pointed out when we approached the group, so we began by looking over some files with them and
identifying why various elements were having strange behavior. We were able to help them problems,
but mostly just design decisions. We suggested they mark the locations of bugs with searchable
comments such as “# ???” so that they could locate them easier instead of just writing down line
numbers (which can change).
We suggested a few coding standards (most of which are in Python’s PEP 8 document) to aid
them in organization of their source. We showed them how to use the python doc-string conventions
(three quotation marks following each class and method) to auto-document their function and generate
the __doc__ special attribute of each object, which then provide information when bringing up
functions while programming in IDLE.
When we were reviewed ourselves, we were cited for a lack of comments. We have tried some
to remedy this but mostly we have attempted to refactor our code to become more clear in itself, since
Python can usually be made to look straightforward. We explained the program flow of our project and
they agreed that it was sensible.