Description:
updated db/schema.rb: removed unused tables
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r277:f3c97d6285dc - - 3 files changed: 10 inserted, 34 deleted
@@ -13,32 +13,24 | |||||
|
13 |
|
13 | ||
|
14 | create_table "announcements", :force => true do |t| |
|
14 | create_table "announcements", :force => true do |t| |
|
15 | t.string "author" |
|
15 | t.string "author" |
|
16 | t.text "body" |
|
16 | t.text "body" |
|
17 | t.boolean "published" |
|
17 | t.boolean "published" |
|
18 | t.datetime "created_at" |
|
18 | t.datetime "created_at" |
|
19 | t.datetime "updated_at" |
|
19 | t.datetime "updated_at" |
|
20 | t.boolean "frontpage", :default => false |
|
20 | t.boolean "frontpage", :default => false |
|
21 | t.boolean "contest_only", :default => false |
|
21 | t.boolean "contest_only", :default => false |
|
22 | t.string "title" |
|
22 | t.string "title" |
|
23 | end |
|
23 | end |
|
24 |
|
24 | ||
|
25 | - create_table "codejom_statuses", :force => true do |t| |
|
||
|
26 | - t.integer "user_id" |
|
||
|
27 | - t.boolean "alive" |
|
||
|
28 | - t.integer "num_problems_passed" |
|
||
|
29 | - t.datetime "created_at" |
|
||
|
30 | - t.datetime "updated_at" |
|
||
|
31 | - end |
|
||
|
32 | - |
|
||
|
33 | create_table "configurations", :force => true do |t| |
|
25 | create_table "configurations", :force => true do |t| |
|
34 | t.string "key" |
|
26 | t.string "key" |
|
35 | t.string "value_type" |
|
27 | t.string "value_type" |
|
36 | t.string "value" |
|
28 | t.string "value" |
|
37 | t.datetime "created_at" |
|
29 | t.datetime "created_at" |
|
38 | t.datetime "updated_at" |
|
30 | t.datetime "updated_at" |
|
39 | t.text "description" |
|
31 | t.text "description" |
|
40 | end |
|
32 | end |
|
41 |
|
33 | ||
|
42 | create_table "contests", :force => true do |t| |
|
34 | create_table "contests", :force => true do |t| |
|
43 | t.string "title" |
|
35 | t.string "title" |
|
44 | t.boolean "enabled" |
|
36 | t.boolean "enabled" |
@@ -147,33 +139,24 | |||||
|
147 | add_index "sessions", ["updated_at"], :name => "index_sessions_on_updated_at" |
|
139 | add_index "sessions", ["updated_at"], :name => "index_sessions_on_updated_at" |
|
148 |
|
140 | ||
|
149 | create_table "sites", :force => true do |t| |
|
141 | create_table "sites", :force => true do |t| |
|
150 | t.string "name" |
|
142 | t.string "name" |
|
151 | t.boolean "started" |
|
143 | t.boolean "started" |
|
152 | t.datetime "start_time" |
|
144 | t.datetime "start_time" |
|
153 | t.datetime "created_at" |
|
145 | t.datetime "created_at" |
|
154 | t.datetime "updated_at" |
|
146 | t.datetime "updated_at" |
|
155 | t.integer "country_id" |
|
147 | t.integer "country_id" |
|
156 | t.string "password" |
|
148 | t.string "password" |
|
157 | end |
|
149 | end |
|
158 |
|
150 | ||
|
159 | - create_table "submission_statuses", :force => true do |t| |
|
||
|
160 | - t.integer "user_id" |
|
||
|
161 | - t.integer "problem_id" |
|
||
|
162 | - t.boolean "passed" |
|
||
|
163 | - t.integer "submission_count" |
|
||
|
164 | - t.datetime "created_at" |
|
||
|
165 | - t.datetime "updated_at" |
|
||
|
166 | - end |
|
||
|
167 | - |
|
||
|
168 | create_table "submissions", :force => true do |t| |
|
151 | create_table "submissions", :force => true do |t| |
|
169 | t.integer "user_id" |
|
152 | t.integer "user_id" |
|
170 | t.integer "problem_id" |
|
153 | t.integer "problem_id" |
|
171 | t.integer "language_id" |
|
154 | t.integer "language_id" |
|
172 | t.text "source" |
|
155 | t.text "source" |
|
173 | t.binary "binary" |
|
156 | t.binary "binary" |
|
174 | t.datetime "submitted_at" |
|
157 | t.datetime "submitted_at" |
|
175 | t.datetime "compiled_at" |
|
158 | t.datetime "compiled_at" |
|
176 | t.text "compiler_message" |
|
159 | t.text "compiler_message" |
|
177 | t.datetime "graded_at" |
|
160 | t.datetime "graded_at" |
|
178 | t.integer "points" |
|
161 | t.integer "points" |
|
179 | t.text "grader_comment" |
|
162 | t.text "grader_comment" |
@@ -182,35 +165,24 | |||||
|
182 | end |
|
165 | end |
|
183 |
|
166 | ||
|
184 | add_index "submissions", ["user_id", "problem_id", "number"], :name => "index_submissions_on_user_id_and_problem_id_and_number", :unique => true |
|
167 | add_index "submissions", ["user_id", "problem_id", "number"], :name => "index_submissions_on_user_id_and_problem_id_and_number", :unique => true |
|
185 | add_index "submissions", ["user_id", "problem_id"], :name => "index_submissions_on_user_id_and_problem_id" |
|
168 | add_index "submissions", ["user_id", "problem_id"], :name => "index_submissions_on_user_id_and_problem_id" |
|
186 |
|
169 | ||
|
187 | create_table "tasks", :force => true do |t| |
|
170 | create_table "tasks", :force => true do |t| |
|
188 | t.integer "submission_id" |
|
171 | t.integer "submission_id" |
|
189 | t.datetime "created_at" |
|
172 | t.datetime "created_at" |
|
190 | t.integer "status" |
|
173 | t.integer "status" |
|
191 | t.datetime "updated_at" |
|
174 | t.datetime "updated_at" |
|
192 | end |
|
175 | end |
|
193 |
|
176 | ||
|
194 | - create_table "test_pair_assignments", :force => true do |t| |
|
||
|
195 | - t.integer "user_id" |
|
||
|
196 | - t.integer "problem_id" |
|
||
|
197 | - t.integer "test_pair_id" |
|
||
|
198 | - t.integer "test_pair_number" |
|
||
|
199 | - t.integer "request_number" |
|
||
|
200 | - t.datetime "created_at" |
|
||
|
201 | - t.datetime "updated_at" |
|
||
|
202 | - t.boolean "submitted" |
|
||
|
203 | - end |
|
||
|
204 | - |
|
||
|
205 | create_table "test_pairs", :force => true do |t| |
|
177 | create_table "test_pairs", :force => true do |t| |
|
206 | t.integer "problem_id" |
|
178 | t.integer "problem_id" |
|
207 | t.text "input", :limit => 16777215 |
|
179 | t.text "input", :limit => 16777215 |
|
208 | t.text "solution", :limit => 16777215 |
|
180 | t.text "solution", :limit => 16777215 |
|
209 | t.datetime "created_at" |
|
181 | t.datetime "created_at" |
|
210 | t.datetime "updated_at" |
|
182 | t.datetime "updated_at" |
|
211 | end |
|
183 | end |
|
212 |
|
184 | ||
|
213 | create_table "test_requests", :force => true do |t| |
|
185 | create_table "test_requests", :force => true do |t| |
|
214 | t.integer "user_id" |
|
186 | t.integer "user_id" |
|
215 | t.integer "problem_id" |
|
187 | t.integer "problem_id" |
|
216 | t.integer "submission_id" |
|
188 | t.integer "submission_id" |
@@ -1,9 +1,13 | |||||
|
1 | # Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html |
|
1 | # Read about fixtures at http://ar.rubyonrails.org/classes/Fixtures.html |
|
2 |
|
2 | ||
|
3 | - one: |
|
3 | + contest_a: |
|
4 | - title: MyString |
|
4 | + title: Contest A |
|
5 |
- enabled: |
|
5 | + enabled: true |
|
6 |
|
6 | ||
|
7 | - two: |
|
7 | + contest_b: |
|
8 | - title: MyString |
|
8 | + title: Contest B |
|
|
9 | + enabled: true | ||
|
|
10 | + | ||
|
|
11 | + contest_c: | ||
|
|
12 | + title: Contest C | ||
|
9 | enabled: false |
|
13 | enabled: false |
@@ -7,23 +7,23 | |||||
|
7 | # in a transaction that's rolled back on completion. This ensures that the |
|
7 | # in a transaction that's rolled back on completion. This ensures that the |
|
8 | # test database remains unchanged so your fixtures don't have to be reloaded |
|
8 | # test database remains unchanged so your fixtures don't have to be reloaded |
|
9 | # between every test method. Fewer database queries means faster tests. |
|
9 | # between every test method. Fewer database queries means faster tests. |
|
10 | # |
|
10 | # |
|
11 | # Read Mike Clark's excellent walkthrough at |
|
11 | # Read Mike Clark's excellent walkthrough at |
|
12 | # http://clarkware.com/cgi/blosxom/2005/10/24#Rails10FastTesting |
|
12 | # http://clarkware.com/cgi/blosxom/2005/10/24#Rails10FastTesting |
|
13 | # |
|
13 | # |
|
14 | # Every Active Record database supports transactions except MyISAM tables |
|
14 | # Every Active Record database supports transactions except MyISAM tables |
|
15 | # in MySQL. Turn off transactional fixtures in this case; however, if you |
|
15 | # in MySQL. Turn off transactional fixtures in this case; however, if you |
|
16 | # don't care one way or the other, switching from MyISAM to InnoDB tables |
|
16 | # don't care one way or the other, switching from MyISAM to InnoDB tables |
|
17 | # is recommended. |
|
17 | # is recommended. |
|
18 |
|
18 | ||
|
19 |
- self.use_transactional_fixtures = |
|
19 | + self.use_transactional_fixtures = true |
|
20 |
|
20 | ||
|
21 | # Instantiated fixtures are slow, but give you @david where otherwise you |
|
21 | # Instantiated fixtures are slow, but give you @david where otherwise you |
|
22 | # would need people(:david). If you don't want to migrate your existing |
|
22 | # would need people(:david). If you don't want to migrate your existing |
|
23 | # test cases which use the @david style and don't mind the speed hit (each |
|
23 | # test cases which use the @david style and don't mind the speed hit (each |
|
24 | # instantiated fixtures translates to a database query per test method), |
|
24 | # instantiated fixtures translates to a database query per test method), |
|
25 | # then set this back to true. |
|
25 | # then set this back to true. |
|
26 | self.use_instantiated_fixtures = false |
|
26 | self.use_instantiated_fixtures = false |
|
27 |
|
27 | ||
|
28 | # Add more helper methods to be used by all tests here... |
|
28 | # Add more helper methods to be used by all tests here... |
|
29 | end |
|
29 | end |
You need to be logged in to leave comments.
Login now