Permalink
Browse files

Configure travis-ci to use database for rake spec

[#46224565]
  • Loading branch information...
1 parent 2604fad commit 0f6b05321ec786355e0aff9b4cf74977d0c5becc @limhoff-r7 limhoff-r7 committed Mar 15, 2013
Showing with 31 additions and 0 deletions.
  1. +4 −0 .travis.yml
  2. +27 −0 config/database.yml.travis
View
@@ -2,6 +2,10 @@ language: ruby
before_install:
- sudo apt-get update -qq
- sudo apt-get install -qq libpcap-dev
+before_script:
+ - cp config/database.yml.travis config/database.yml
+ - rake db:create
+ - rake db:migrate
rvm:
#- '1.8.7'
View
@@ -0,0 +1,27 @@
+# @note This file is only for use in travis-ci. If you need to make a
+# config/database.yml for running rake, rake spec, or rspec locally, please
+# customize `conifg/database.yml.example`
+#
+# @example Customizing config/database.yml.example
+# cp config/database.yml.example config/database.yml
+# # update password fields for each environment's user
+
+# Using the postgres user locally without a host and port is the supported
+# configuration from Travis-CI
+#
+# @see http://about.travis-ci.org/docs/user/database-setup/#PostgreSQL
+development: &pgsql
+ adapter: postgresql
+ database: metasploit_framework_development
+ username: postgres
+ pool: 5
+ timeout: 5
+
+# Warning: The database defined as "test" will be erased and
+# re-generated from your development database when you run "rake".
+# Do not set this db to the same as development or production.
+#
+# Note also, sqlite3 is totally unsupported by Metasploit now.
+test:
+ <<: *pgsql
+ database: metasploit_framework_test

0 comments on commit 0f6b053

Please sign in to comment.