Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Looking for instructions on setting up the course environment?
Our recommended setup is to use Cloud9, or if that's not practical, to start from a clean Ubuntu image such as you might get from Amazon EC2. Cloud9 and "clean Ubuntu" setups have been field-tested with these materials. The other setup approaches contributed by other users may or may not work for you. Each setup approach has its own wiki page with instructions.
Looking for information on the homeworks?
As of August 2015, these have been updated to work with Ruby ~>2.2, Rails ~>4.2, and RSpec ~>3.3.
Each homework has its own Wiki page with more detailed instructions and tips from other instructors. Here's a quick summary of the assignments, presented in the order in which we usually use them at Berkeley.
Note that each homework has two associated repos. Repo
hw-foo is public, and contains student-facing materials such as instructions, scaffolding, and starter code. Repo
-ci is private to instructors, and contains the reference solution and other instructor materials. The
-ci repo is also used with Travis CI to ensure that whenever changes are made to the homework or reference solution, it still passes the autograder correctly.
- Ruby Intro: gentle intro to Ruby idioms, including running instructor-provided unit tests to check your answers. More
- Oracle of Bacon: students build a simple command-line app that uses external services in a SOA, including parsing XML responses. In this case the external service is the Oracle of Bacon, which computes the number of degrees of separation between actor Kevin Bacon and virtually any other actor. Also provides more practice with RSpec. More
- Sinatra Hangperson: de-mystifies the creation of a SaaS app, how SaaS components map onto pieces of code, how to make use of external services in a service-oriented architecture (in this case, we use an external service that chooses a random word to start the game), and most importantly, how to think about "wrapping" an existing application in a SaaS framework using RESTful (Representational State Transfer) design. More
- Rails Hangperson: Uses the exact same game logic and Cucumber scenarios as Sinatra Hangperson, but scaffolds a walkthrough of how to deploy the app with Rails instead of Sinatra. This lets students gently migrate their SaaS and Sinatra knowledge to the much more complex Rails framework. More
- Rails Intro: add a feature to the RottenPotatoes teaching app to filter lists of movies by rating, sort by date, etc. The amount of functionality to add is not large, but it requires students to grapple with the more complex Rails framework and understand how the moving parts go together. More
- BDD with Cucumber: students write features to test happy and sad paths of an existing app, as a way to start thinking about how to write Cucumber scenarios. The autograder inserts various bugs into a reference app to check the students' scenarios. More
- BDD/TDD Cycle: a complete pass through the BDD and TDD cycle of specifying a feature in terms of stories and then using TDD with RSpec to drive the development and deployment of the feature. More
- Legacy Code - new feature: students enhance a 30,000 line Rails legacy app (the blog engine Typo) with a new feature. This assignment probably most resembles what most students will be asked to do on their first industry software engineering job. More
- Legacy Code - fix bug: students fix a bug in a 30,000 line Rails legacy app (the blog engine Typo). More
- SaaS Performance: improve the performance of RottenPotatoes by adding caching and database indices. More