mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-22 07:04:09 +01:00
all unit and functional tests are passing
This commit is contained in:
parent
96db48dd86
commit
13b58f3a10
40 changed files with 1107 additions and 1494 deletions
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue