about summary refs log tree commit diff stats
path: root/test
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2018-01-13 16:01:51 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2018-01-13 16:01:51 -0500
commit7e4b9ea0c23eb660ab36a6114a7a3046d8f1c5f6 (patch)
treed2e020ca045ce3d6f28a6d912bbc343db03265d2 /test
parentd91e1d9a9ee98cc364bc62a4dd156500a189b99a (diff)
downloadpokeviewer-7e4b9ea0c23eb660ab36a6114a7a3046d8f1c5f6.tar.gz
pokeviewer-7e4b9ea0c23eb660ab36a6114a7a3046d8f1c5f6.tar.bz2
pokeviewer-7e4b9ea0c23eb660ab36a6114a7a3046d8f1c5f6.zip
Moved species from Pokémon to revision
The migration will set all of the revisions of each Pokémon to have the species that that Pokémon was set to. If reversed, the migration sets the Pokémon's species to the first revision's species, which mimics the behavior of the engine from before this change, but do note that running the migration backwards like this can lose data.

This change slightly affects the loading time of the front page. See #2.

refs #3
Diffstat (limited to 'test')
-rw-r--r--test/dummy/db/schema.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/dummy/db/schema.rb b/test/dummy/db/schema.rb index a527d06..9752892 100644 --- a/test/dummy/db/schema.rb +++ b/test/dummy/db/schema.rb
@@ -10,7 +10,7 @@
10# 10#
11# It's strongly recommended that you check this file into your version control system. 11# It's strongly recommended that you check this file into your version control system.
12 12
13ActiveRecord::Schema.define(version: 20171011015648) do 13ActiveRecord::Schema.define(version: 20180113200119) do
14 14
15 create_table "pokeviewer_abilities", force: :cascade do |t| 15 create_table "pokeviewer_abilities", force: :cascade do |t|
16 t.string "name", limit: 191, null: false 16 t.string "name", limit: 191, null: false
@@ -58,7 +58,6 @@ ActiveRecord::Schema.define(version: 20171011015648) do
58 58
59 create_table "pokeviewer_pokemon", force: :cascade do |t| 59 create_table "pokeviewer_pokemon", force: :cascade do |t|
60 t.string "uuid", limit: 191, null: false 60 t.string "uuid", limit: 191, null: false
61 t.integer "species_id", null: false
62 t.integer "trainer_id" 61 t.integer "trainer_id"
63 t.string "key", limit: 191 62 t.string "key", limit: 191
64 t.string "ot_name", null: false 63 t.string "ot_name", null: false
@@ -78,7 +77,6 @@ ActiveRecord::Schema.define(version: 20171011015648) do
78 t.integer "location_id" 77 t.integer "location_id"
79 t.string "pokeball", null: false 78 t.string "pokeball", null: false
80 t.index ["key"], name: "index_pokeviewer_pokemon_on_key", unique: true 79 t.index ["key"], name: "index_pokeviewer_pokemon_on_key", unique: true
81 t.index ["species_id"], name: "index_pokeviewer_pokemon_on_species_id"
82 t.index ["trainer_id"], name: "index_pokeviewer_pokemon_on_trainer_id" 80 t.index ["trainer_id"], name: "index_pokeviewer_pokemon_on_trainer_id"
83 t.index ["uuid"], name: "index_pokeviewer_pokemon_on_uuid", unique: true 81 t.index ["uuid"], name: "index_pokeviewer_pokemon_on_uuid", unique: true
84 end 82 end
@@ -129,12 +127,14 @@ ActiveRecord::Schema.define(version: 20171011015648) do
129 t.boolean "national_ribbon", default: false 127 t.boolean "national_ribbon", default: false
130 t.boolean "earth_ribbon", default: false 128 t.boolean "earth_ribbon", default: false
131 t.boolean "world_ribbon", default: false 129 t.boolean "world_ribbon", default: false
130 t.integer "species_id", null: false
132 t.index ["move_1_id"], name: "index_pokeviewer_revisions_on_move_1_id" 131 t.index ["move_1_id"], name: "index_pokeviewer_revisions_on_move_1_id"
133 t.index ["move_2_id"], name: "index_pokeviewer_revisions_on_move_2_id" 132 t.index ["move_2_id"], name: "index_pokeviewer_revisions_on_move_2_id"
134 t.index ["move_3_id"], name: "index_pokeviewer_revisions_on_move_3_id" 133 t.index ["move_3_id"], name: "index_pokeviewer_revisions_on_move_3_id"
135 t.index ["move_4_id"], name: "index_pokeviewer_revisions_on_move_4_id" 134 t.index ["move_4_id"], name: "index_pokeviewer_revisions_on_move_4_id"
136 t.index ["pokemon_id", "sequential_id"], name: "index_pokeviewer_revisions_on_pokemon_id_and_sequential_id", unique: true 135 t.index ["pokemon_id", "sequential_id"], name: "index_pokeviewer_revisions_on_pokemon_id_and_sequential_id", unique: true
137 t.index ["pokemon_id"], name: "index_pokeviewer_revisions_on_pokemon_id" 136 t.index ["pokemon_id"], name: "index_pokeviewer_revisions_on_pokemon_id"
137 t.index ["species_id"], name: "index_pokeviewer_revisions_on_species_id"
138 end 138 end
139 139
140 create_table "pokeviewer_species", force: :cascade do |t| 140 create_table "pokeviewer_species", force: :cascade do |t|