diff --git a/Gemfile b/Gemfile index 62495d3c83..07ab3a68fa 100644 --- a/Gemfile +++ b/Gemfile @@ -4,3 +4,4 @@ gem 'sinatra' gem 'sinatra-activerecord' gem 'mysql2' gem 'rake' +gem 'minitest' diff --git a/Gemfile.lock b/Gemfile.lock index a2236d168a..42dc4fec56 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -40,6 +40,7 @@ PLATFORMS ruby DEPENDENCIES + minitest mysql2 rake sinatra diff --git a/Rakefile b/Rakefile index 41d84a7a9f..bc0cb8f548 100644 --- a/Rakefile +++ b/Rakefile @@ -1,4 +1,12 @@ +require 'bundler' + require_relative 'config/database' require_relative 'models' + require 'sinatra/activerecord/rake' +require 'rake/testtask' +Rake::TestTask.new do |t| + t.pattern = "test/*_test.rb" + t.verbose = true +end diff --git a/test/sample_test.rb b/test/sample_test.rb new file mode 100644 index 0000000000..8f1b5fb764 --- /dev/null +++ b/test/sample_test.rb @@ -0,0 +1,10 @@ +require 'bundler' +require 'minitest/autorun' + +class TestSample < Minitest::Test + + def test_sample + assert_equal "Foo", "Foo" + end + +end