Commit 9bb86c44 authored by jplang's avatar jplang

Test failures.

git-svn-id: https://svn.redmine.org/redmine/trunk@16359 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 85b1d0e3
......@@ -24,6 +24,11 @@ class Redmine::VersionFieldFormatTest < ActionView::TestCase
:issue_statuses, :issue_categories, :issue_relations, :workflows,
:enumerations
def setup
super
User.current = nil
end
def test_version_status_should_reject_blank_values
field = IssueCustomField.new(:name => 'Foo', :field_format => 'version', :version_status => ["open", ""])
field.save!
......
......@@ -37,7 +37,8 @@ class ProjectTest < ActiveSupport::TestCase
:repositories,
:news, :comments,
:documents,
:workflows
:workflows,
:attachments
def setup
@ecookbook = Project.find(1)
......
......@@ -68,13 +68,15 @@ class TimeEntryQueryTest < ActiveSupport::TestCase
TimeEntry.generate!(:activity => override, :hours => 2.0)
TimeEntry.generate!(:activity => other, :hours => 4.0)
query = TimeEntryQuery.new(:name => '_')
query.add_filter('activity_id', '=', [system.id.to_s])
assert_equal 3.0, query.results_scope.sum(:hours)
query = TimeEntryQuery.new(:name => '_')
query.add_filter('activity_id', '!', [system.id.to_s])
assert_equal 4.0, query.results_scope.sum(:hours)
with_current_user User.find(2) do
query = TimeEntryQuery.new(:name => '_')
query.add_filter('activity_id', '=', [system.id.to_s])
assert_equal 3.0, query.results_scope.sum(:hours)
query = TimeEntryQuery.new(:name => '_')
query.add_filter('activity_id', '!', [system.id.to_s])
assert_equal 4.0, query.results_scope.sum(:hours)
end
end
def test_project_query_should_include_project_issue_custom_fields_only_as_filters
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment