all unit and functional tests are passing

This commit is contained in:
Reinier Balt 2012-04-24 20:47:07 +02:00
parent 96db48dd86
commit 13b58f3a10
40 changed files with 1107 additions and 1494 deletions

View file

@ -54,12 +54,6 @@ class ContextTest < ActiveSupport::TestCase
assert_equal @agenda.name, @agenda.title
end
def test_feed_options
opts = Context.feed_options(users(:admin_user))
assert_equal 'Tracks Contexts', opts[:title], 'Unexpected value for :title key of feed_options'
assert_equal 'Lists all the contexts for Admin Schmadmin', opts[:description], 'Unexpected value for :description key of feed_options'
end
def test_hidden_attr_reader
assert !@agenda.hidden?
@agenda.hide = true

View file

@ -128,12 +128,6 @@ class ProjectTest < ActiveSupport::TestCase
assert p.nil?
assert_nil p.id
end
def test_feed_options
opts = Project.feed_options(users(:admin_user))
assert_equal 'Tracks Projects', opts[:title], 'Unexpected value for :title key of feed_options'
assert_equal 'Lists all the projects for Admin Schmadmin', opts[:description], 'Unexpected value for :description key of feed_options'
end
def test_name_removes_extra_spaces
newproj = Project.new

View file

@ -1,5 +1,4 @@
require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
require 'date'
class TodoTest < ActiveSupport::TestCase
fixtures :todos, :recurring_todos, :users, :contexts, :preferences, :tags, :taggings, :projects

View file

@ -1,13 +1,5 @@
require File.expand_path(File.dirname(__FILE__) + '/../test_helper')
module Tracks
class Config
def self.auth_schemes
['database', 'ldap']
end
end
end
class SimpleLdapAuthenticator
cattr_accessor :fake_success
@ -22,7 +14,7 @@ class UserTest < ActiveSupport::TestCase
def setup
assert_equal "test", ENV['RAILS_ENV']
assert_equal "change-me", Tracks::Config.salt
assert_equal ['database', 'ldap'], Tracks::Config.auth_schemes
assert Tracks::Config.auth_schemes.include?('ldap')
@admin_user = User.find(1)
@other_user = User.find(2)
end