Website for tinkuy.dk.
createuser -s -r $USERNAME
as postgresstart
rails server
psql tinkuy_development
There are automated tests, with support for continuous integration through travis.ci. We have two kinds of tests at the moment: unit testing and functional testing
We are just using rake test
which comes built in with ruby. Unfortunately it is a bit out of date, and thus all tests are disabled at the moment; test/fixtures
, test/controllers
, etc. needs to be updated before this makes sense.
Currently we just start the rails server
, fetch some pages, and compare them with what we expect. This is executed by running test2/run-blackbox-testing.sh
in the project root, which then reinitialises the tinkuy_test
database, starts rails server
, fetches a number of webpages into test2/result
, and compares that with the expected value in test2/expected
.
Important: when changes are done that affects the outpage of the pages, this test will likely fail, - verify that the behaviour is as expected, and then move the content of test2/result
into test2/expected
.
This is just a quick hack to be able to test, if the application runs, and has the expected output. On the long run, it would make sense to replace this with a selenium tests, or similar.
There is an sample database in test2/sample-db.pgsql.xz
. All user information has been anonymised, and every user has the password 12345678
. Some user logins with different roles are:
When there are changes in schema, then the sample database needs to be migrated: first load database, then migrate, and then store the new one, ie.:
git@heroku.com:tinkuy-staging.git