mirror of
https://github.com/oonyeje/Pearlception_Website_RoR.git
synced 2025-12-25 11:47:41 +00:00
add env vars support in config
This commit is contained in:
parent
92b58aa680
commit
c8a1989c11
@ -21,9 +21,9 @@ stats_development: &stats
|
|||||||
adapter: mysql2
|
adapter: mysql2
|
||||||
encoding: utf8
|
encoding: utf8
|
||||||
pool: 5
|
pool: 5
|
||||||
username: ivauser
|
username: <%= ENV['STATS_DB_USER'] %>
|
||||||
password: <%= ENV['DB_PASS'] %>
|
password: <%= ENV['STATS_DB_PASS'] %>
|
||||||
host: taylors.c02zesysnssi.us-west-2.rds.amazonaws.com
|
host: <%= ENV['STATS_DB_URL'] %>
|
||||||
port: 3306
|
port: 3306
|
||||||
database: main
|
database: main
|
||||||
|
|
||||||
|
|||||||
@ -1,9 +1,17 @@
|
|||||||
require 'test_helper'
|
require 'test_helper'
|
||||||
|
|
||||||
class OysterTest < ActiveSupport::TestCase
|
class OysterTest < ActiveSupport::TestCase
|
||||||
test "the_truth" do
|
|
||||||
f = Oyster.first
|
test "check_connection" do
|
||||||
puts f.inspect
|
Oyster.connection
|
||||||
assert true
|
assert true
|
||||||
end
|
end
|
||||||
|
|
||||||
|
test "get_first_oyster" do
|
||||||
|
first = Oyster.first
|
||||||
|
id = first.oyster_id == 1
|
||||||
|
run = first.run_id == 257
|
||||||
|
grade = first.grade == "Rej"
|
||||||
|
assert id && run && grade
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user