-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathREADME
More file actions
49 lines (34 loc) · 1.86 KB
/
README
File metadata and controls
49 lines (34 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
==Centro Technology Developer Candidate Exercises
This are exercises to test your aptitude for developing Rails apps.
This application is a very simple media planning application, similar to the one
we work on every day at Centro.
==Models
* Placement - The Placement of a display advertisement on a website. The
placement runs from the start_date until the end_date.
* Buy - A Buy is a collection of Placements that will run on a site.
* Plan - A Plan is a collection of Buys purchased by an advertiser.
Buys consist of Placements of advertisements to be run on one or more sites.
==Tests
The tests use Thoughtbot's Shoulda and FactoryGirl (both included in vendor/gems).
Documentation is available at http://www.thoughtbot.com/projects
==Exercises
1. Currently, a Buy only has its site's name stored in an instance variable.
We've generated a resource called Site for you. Please complete the following user
stories and provide tests for your code.
* A Site can have many Buys. A Buy can have one Site.
* A Site has a name, an URL and a billing contact (you don't need to implement
a Contact model).
* Replace the site_name field on Buy with the Site model.
* Write a finder on Plan to find all plans with Buys for a given Site.
2. The application currently has no user interface. Complete these stories with
well-tested code. Don't worry about making it look awesome, just make it work.
* As a user, I can create a new Plan.
* As a user, I can add Buys to a Plan.
* As a user, I can add a Site or @site_name to a Buy.
* As a user, I can add and edit Placements on a Buy.
* As a user, I cannot save a Plan unless it has at least one Buy.
* As a user, I cannot save a Buy unless it has a Site or @site_name and at least one
Placement.
==When you're finished
* Create a branch with your solution on it.
* Send a Github pull request or any clone url to developers@centro.net