This document provides an overview of the technologies used in a ticket sales application including: HTML5, JavaScript, Ruby on Rails, HTTP, databases like MongoDB and Solr, web servers like Apache and Nginx, Linux distributions like Gentoo, and cloud platforms like Amazon EC2. It also describes the application architecture with Rails applications behind load balancers, a master database, and an automated testing approach using behavior-driven development with tools like Cucumber and RSpec. Finally, it shows examples of behavioral specifications, unit tests, and a Kanban project management board.
2. HTML5 Mobile HTML5
API
JavaScript
Ruby on Rails
HTTP Data
Passenger Redis MongoDB Solr
Apache MySQL
Gentoo Linux
Engine Yard AppCloud
Amazon EC2
Technology Stack
3. Application Master
Rails HAProxy
Apache
Application Application
Rails Rails
Apache Apache
Master Database
Redis MongoDB Solr
MySQL
Production Cluster
5. Event 1 Event 2 Event 3
Reservation 1 Reservation 1 Ticket Type 1
Reservation 2 Guest List 1 Ticket Sale 1
Guest List 1 Guest 1 Ticket Sale 2
Guest 1 Guest 2 Ticket Sale 3
Guest 2 Guest List 2 Ticket Sale 4
Ticket Type 1 Guest 1
Ticket Type 2
Ticket Sale 1 Guest 2 Ticket Sale 1
Ticket Sale 1 Ticket Sale 2
Event Report Documents
10. Scenario: The customer should see a PDF link at the
end of the purchase process.
Given an event "Test Event"
And 2 active "General Admission" tickets at 10 dollars
And the event "Test Event" is active,
When I go to the ticket sales page
And I follow the buy tickets link for "Test Event"
And I press "checkout"
And I submit valid payment details,
Then I should see "download your ticket here".
Example Behavioral Specification
11. def test_generates_valid_hard_ticket_code
ticket_sale = TicketSale.create(
:event_id => @event.id, :quantity => 2
)
hard_code = ticket_sale.generate_hard_ticket_code
assert TicketSale.valid_hard_ticket_code? hard_code
end
Example Unit Test