Adds missing native eol properties.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2895 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
52a6b0a21e
commit
21e18c1eb4
|
@ -1,38 +1,38 @@
|
|||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
class Principal < ActiveRecord::Base
|
||||
set_table_name 'users'
|
||||
|
||||
has_many :members, :foreign_key => 'user_id', :dependent => :destroy
|
||||
has_many :memberships, :class_name => 'Member', :foreign_key => 'user_id', :include => [ :project, :roles ], :conditions => "#{Project.table_name}.status=#{Project::STATUS_ACTIVE}", :order => "#{Project.table_name}.name"
|
||||
has_many :projects, :through => :memberships
|
||||
|
||||
# Groups and active users
|
||||
named_scope :active, :conditions => "#{Principal.table_name}.type='Group' OR (#{Principal.table_name}.type='User' AND #{Principal.table_name}.status = 1)"
|
||||
|
||||
named_scope :like, lambda {|q|
|
||||
s = "%#{q.to_s.strip.downcase}%"
|
||||
{:conditions => ["LOWER(login) LIKE ? OR LOWER(firstname) LIKE ? OR LOWER(lastname) LIKE ?", s, s, s],
|
||||
:order => 'type, login, lastname, firstname'
|
||||
}
|
||||
}
|
||||
|
||||
def <=>(principal)
|
||||
self.to_s.downcase <=> principal.to_s.downcase
|
||||
end
|
||||
end
|
||||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
class Principal < ActiveRecord::Base
|
||||
set_table_name 'users'
|
||||
|
||||
has_many :members, :foreign_key => 'user_id', :dependent => :destroy
|
||||
has_many :memberships, :class_name => 'Member', :foreign_key => 'user_id', :include => [ :project, :roles ], :conditions => "#{Project.table_name}.status=#{Project::STATUS_ACTIVE}", :order => "#{Project.table_name}.name"
|
||||
has_many :projects, :through => :memberships
|
||||
|
||||
# Groups and active users
|
||||
named_scope :active, :conditions => "#{Principal.table_name}.type='Group' OR (#{Principal.table_name}.type='User' AND #{Principal.table_name}.status = 1)"
|
||||
|
||||
named_scope :like, lambda {|q|
|
||||
s = "%#{q.to_s.strip.downcase}%"
|
||||
{:conditions => ["LOWER(login) LIKE ? OR LOWER(firstname) LIKE ? OR LOWER(lastname) LIKE ?", s, s, s],
|
||||
:order => 'type, login, lastname, firstname'
|
||||
}
|
||||
}
|
||||
|
||||
def <=>(principal)
|
||||
self.to_s.downcase <=> principal.to_s.downcase
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,16 +1,16 @@
|
|||
<h3><%=l(:label_watched_issues)%> (<%= Issue.visible.count(:include => :watchers,
|
||||
:conditions => ["#{Watcher.table_name}.user_id = ?", user.id]) %>)</h3>
|
||||
<% watched_issues = Issue.visible.find(:all,
|
||||
:include => [:status, :project, :tracker, :watchers],
|
||||
:limit => 10,
|
||||
:conditions => ["#{Watcher.table_name}.user_id = ?", user.id],
|
||||
:order => "#{Issue.table_name}.updated_on DESC") %>
|
||||
|
||||
<%= render :partial => 'issues/list_simple', :locals => { :issues => watched_issues } %>
|
||||
<% if watched_issues.length > 0 %>
|
||||
<p class="small"><%= link_to l(:label_issue_view_all), :controller => 'issues',
|
||||
:action => 'index',
|
||||
:set_filter => 1,
|
||||
:watcher_id => 'me',
|
||||
:sort => 'updated_on:desc' %></p>
|
||||
<% end %>
|
||||
<h3><%=l(:label_watched_issues)%> (<%= Issue.visible.count(:include => :watchers,
|
||||
:conditions => ["#{Watcher.table_name}.user_id = ?", user.id]) %>)</h3>
|
||||
<% watched_issues = Issue.visible.find(:all,
|
||||
:include => [:status, :project, :tracker, :watchers],
|
||||
:limit => 10,
|
||||
:conditions => ["#{Watcher.table_name}.user_id = ?", user.id],
|
||||
:order => "#{Issue.table_name}.updated_on DESC") %>
|
||||
|
||||
<%= render :partial => 'issues/list_simple', :locals => { :issues => watched_issues } %>
|
||||
<% if watched_issues.length > 0 %>
|
||||
<p class="small"><%= link_to l(:label_issue_view_all), :controller => 'issues',
|
||||
:action => 'index',
|
||||
:set_filter => 1,
|
||||
:watcher_id => 'me',
|
||||
:sort => 'updated_on:desc' %></p>
|
||||
<% end %>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<h2><%= l(:label_query_new) %></h2>
|
||||
|
||||
<% form_tag({:action => 'new', :project_id => @query.project}, :onsubmit => 'selectAllOptions("selected_columns");') do %>
|
||||
<%= render :partial => 'form', :locals => {:query => @query} %>
|
||||
<%= submit_tag l(:button_save) %>
|
||||
<% end %>
|
||||
<h2><%= l(:label_query_new) %></h2>
|
||||
|
||||
<% form_tag({:action => 'new', :project_id => @query.project}, :onsubmit => 'selectAllOptions("selected_columns");') do %>
|
||||
<%= render :partial => 'form', :locals => {:query => @query} %>
|
||||
<%= submit_tag l(:button_save) %>
|
||||
<% end %>
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
<h2><%= l(:label_statistics) %></h2>
|
||||
|
||||
<p>
|
||||
<%= tag("embed", :width => 800, :height => 300, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :graph => "commits_per_month")) %>
|
||||
</p>
|
||||
<p>
|
||||
<%= tag("embed", :width => 800, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :graph => "commits_per_author")) %>
|
||||
</p>
|
||||
|
||||
<p><%= link_to l(:button_back), :action => 'show', :id => @project %></p>
|
||||
|
||||
<% html_title(l(:label_repository), l(:label_statistics)) -%>
|
||||
<h2><%= l(:label_statistics) %></h2>
|
||||
|
||||
<p>
|
||||
<%= tag("embed", :width => 800, :height => 300, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :graph => "commits_per_month")) %>
|
||||
</p>
|
||||
<p>
|
||||
<%= tag("embed", :width => 800, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :graph => "commits_per_author")) %>
|
||||
</p>
|
||||
|
||||
<p><%= link_to l(:button_back), :action => 'show', :id => @project %></p>
|
||||
|
||||
<% html_title(l(:label_repository), l(:label_statistics)) -%>
|
||||
|
|
|
@ -1,51 +1,51 @@
|
|||
<h2><%= l(:label_search) %></h2>
|
||||
|
||||
<div class="box">
|
||||
<% form_tag({}, :method => :get) do %>
|
||||
<p><%= text_field_tag 'q', @question, :size => 60, :id => 'search-input' %>
|
||||
<%= javascript_tag "Field.focus('search-input')" %>
|
||||
<%= project_select_tag %>
|
||||
<label><%= check_box_tag 'all_words', 1, @all_words %> <%= l(:label_all_words) %></label>
|
||||
<label><%= check_box_tag 'titles_only', 1, @titles_only %> <%= l(:label_search_titles_only) %></label>
|
||||
</p>
|
||||
<p>
|
||||
<% @object_types.each do |t| %>
|
||||
<label><%= check_box_tag t, 1, @scope.include?(t) %> <%= type_label(t) %></label>
|
||||
<% end %>
|
||||
</p>
|
||||
|
||||
<p><%= submit_tag l(:button_submit), :name => 'submit' %></p>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% if @results %>
|
||||
<div id="search-results-counts">
|
||||
<%= render_results_by_type(@results_by_type) unless @scope.size == 1 %>
|
||||
</div>
|
||||
|
||||
<h3><%= l(:label_result_plural) %> (<%= @results_by_type.values.sum %>)</h3>
|
||||
<dl id="search-results">
|
||||
<% @results.each do |e| %>
|
||||
<dt class="<%= e.event_type %>"><%= content_tag('span', h(e.project), :class => 'project') unless @project == e.project %> <%= link_to highlight_tokens(truncate(e.event_title, :length => 255), @tokens), e.event_url %></dt>
|
||||
<dd><span class="description"><%= highlight_tokens(e.event_description, @tokens) %></span>
|
||||
<span class="author"><%= format_time(e.event_datetime) %></span></dd>
|
||||
<% end %>
|
||||
</dl>
|
||||
<% end %>
|
||||
|
||||
<p><center>
|
||||
<% if @pagination_previous_date %>
|
||||
<%= link_to_remote ('« ' + l(:label_previous)),
|
||||
{:update => :content,
|
||||
:url => params.merge(:previous => 1, :offset => @pagination_previous_date.strftime("%Y%m%d%H%M%S"))
|
||||
}, :href => url_for(params.merge(:previous => 1, :offset => @pagination_previous_date.strftime("%Y%m%d%H%M%S"))) %>
|
||||
<% end %>
|
||||
<% if @pagination_next_date %>
|
||||
<%= link_to_remote (l(:label_next) + ' »'),
|
||||
{:update => :content,
|
||||
:url => params.merge(:previous => nil, :offset => @pagination_next_date.strftime("%Y%m%d%H%M%S"))
|
||||
}, :href => url_for(params.merge(:previous => nil, :offset => @pagination_next_date.strftime("%Y%m%d%H%M%S"))) %>
|
||||
<% end %>
|
||||
</center></p>
|
||||
|
||||
<% html_title(l(:label_search)) -%>
|
||||
<h2><%= l(:label_search) %></h2>
|
||||
|
||||
<div class="box">
|
||||
<% form_tag({}, :method => :get) do %>
|
||||
<p><%= text_field_tag 'q', @question, :size => 60, :id => 'search-input' %>
|
||||
<%= javascript_tag "Field.focus('search-input')" %>
|
||||
<%= project_select_tag %>
|
||||
<label><%= check_box_tag 'all_words', 1, @all_words %> <%= l(:label_all_words) %></label>
|
||||
<label><%= check_box_tag 'titles_only', 1, @titles_only %> <%= l(:label_search_titles_only) %></label>
|
||||
</p>
|
||||
<p>
|
||||
<% @object_types.each do |t| %>
|
||||
<label><%= check_box_tag t, 1, @scope.include?(t) %> <%= type_label(t) %></label>
|
||||
<% end %>
|
||||
</p>
|
||||
|
||||
<p><%= submit_tag l(:button_submit), :name => 'submit' %></p>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% if @results %>
|
||||
<div id="search-results-counts">
|
||||
<%= render_results_by_type(@results_by_type) unless @scope.size == 1 %>
|
||||
</div>
|
||||
|
||||
<h3><%= l(:label_result_plural) %> (<%= @results_by_type.values.sum %>)</h3>
|
||||
<dl id="search-results">
|
||||
<% @results.each do |e| %>
|
||||
<dt class="<%= e.event_type %>"><%= content_tag('span', h(e.project), :class => 'project') unless @project == e.project %> <%= link_to highlight_tokens(truncate(e.event_title, :length => 255), @tokens), e.event_url %></dt>
|
||||
<dd><span class="description"><%= highlight_tokens(e.event_description, @tokens) %></span>
|
||||
<span class="author"><%= format_time(e.event_datetime) %></span></dd>
|
||||
<% end %>
|
||||
</dl>
|
||||
<% end %>
|
||||
|
||||
<p><center>
|
||||
<% if @pagination_previous_date %>
|
||||
<%= link_to_remote ('« ' + l(:label_previous)),
|
||||
{:update => :content,
|
||||
:url => params.merge(:previous => 1, :offset => @pagination_previous_date.strftime("%Y%m%d%H%M%S"))
|
||||
}, :href => url_for(params.merge(:previous => 1, :offset => @pagination_previous_date.strftime("%Y%m%d%H%M%S"))) %>
|
||||
<% end %>
|
||||
<% if @pagination_next_date %>
|
||||
<%= link_to_remote (l(:label_next) + ' »'),
|
||||
{:update => :content,
|
||||
:url => params.merge(:previous => nil, :offset => @pagination_next_date.strftime("%Y%m%d%H%M%S"))
|
||||
}, :href => url_for(params.merge(:previous => nil, :offset => @pagination_next_date.strftime("%Y%m%d%H%M%S"))) %>
|
||||
<% end %>
|
||||
</center></p>
|
||||
|
||||
<% html_title(l(:label_search)) -%>
|
||||
|
|
|
@ -1,35 +1,35 @@
|
|||
<div class="contextual">
|
||||
<%= link_to_if_authorized l(:button_log_time), {:controller => 'timelog', :action => 'edit', :project_id => @project, :issue_id => @issue}, :class => 'icon icon-time-add' %>
|
||||
</div>
|
||||
|
||||
<%= render_timelog_breadcrumb %>
|
||||
|
||||
<h2><%= l(:label_spent_time) %></h2>
|
||||
|
||||
<% form_remote_tag( :url => {}, :html => {:method => :get, :id => 'query_form'}, :method => :get, :update => 'content' ) do %>
|
||||
<%# TOOD: remove the project_id and issue_id hidden fields, that information is
|
||||
already in the URI %>
|
||||
<%= hidden_field_tag('project_id', params[:project_id]) if @project %>
|
||||
<%= hidden_field_tag 'issue_id', params[:issue_id] if @issue %>
|
||||
<%= render :partial => 'date_range' %>
|
||||
<% end %>
|
||||
|
||||
<div class="total-hours">
|
||||
<p><%= l(:label_total) %>: <%= html_hours(l_hours(@total_hours)) %></p>
|
||||
</div>
|
||||
|
||||
<% unless @entries.empty? %>
|
||||
<%= render :partial => 'list', :locals => { :entries => @entries }%>
|
||||
<p class="pagination"><%= pagination_links_full @entry_pages, @entry_count %></p>
|
||||
|
||||
<% other_formats_links do |f| %>
|
||||
<%= f.link_to 'Atom', :url => params.merge({:issue_id => @issue, :key => User.current.rss_key}) %>
|
||||
<%= f.link_to 'CSV', :url => params %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% html_title l(:label_spent_time), l(:label_details) %>
|
||||
|
||||
<% content_for :header_tags do %>
|
||||
<%= auto_discovery_link_tag(:atom, {:issue_id => @issue, :format => 'atom', :key => User.current.rss_key}, :title => l(:label_spent_time)) %>
|
||||
<% end %>
|
||||
<div class="contextual">
|
||||
<%= link_to_if_authorized l(:button_log_time), {:controller => 'timelog', :action => 'edit', :project_id => @project, :issue_id => @issue}, :class => 'icon icon-time-add' %>
|
||||
</div>
|
||||
|
||||
<%= render_timelog_breadcrumb %>
|
||||
|
||||
<h2><%= l(:label_spent_time) %></h2>
|
||||
|
||||
<% form_remote_tag( :url => {}, :html => {:method => :get, :id => 'query_form'}, :method => :get, :update => 'content' ) do %>
|
||||
<%# TOOD: remove the project_id and issue_id hidden fields, that information is
|
||||
already in the URI %>
|
||||
<%= hidden_field_tag('project_id', params[:project_id]) if @project %>
|
||||
<%= hidden_field_tag 'issue_id', params[:issue_id] if @issue %>
|
||||
<%= render :partial => 'date_range' %>
|
||||
<% end %>
|
||||
|
||||
<div class="total-hours">
|
||||
<p><%= l(:label_total) %>: <%= html_hours(l_hours(@total_hours)) %></p>
|
||||
</div>
|
||||
|
||||
<% unless @entries.empty? %>
|
||||
<%= render :partial => 'list', :locals => { :entries => @entries }%>
|
||||
<p class="pagination"><%= pagination_links_full @entry_pages, @entry_count %></p>
|
||||
|
||||
<% other_formats_links do |f| %>
|
||||
<%= f.link_to 'Atom', :url => params.merge({:issue_id => @issue, :key => User.current.rss_key}) %>
|
||||
<%= f.link_to 'CSV', :url => params %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% html_title l(:label_spent_time), l(:label_details) %>
|
||||
|
||||
<% content_for :header_tags do %>
|
||||
<%= auto_discovery_link_tag(:atom, {:issue_id => @issue, :format => 'atom', :key => User.current.rss_key}, :title => l(:label_spent_time)) %>
|
||||
<% end %>
|
||||
|
|
|
@ -1,21 +1,21 @@
|
|||
<h2><%= l(:label_spent_time) %></h2>
|
||||
|
||||
<% labelled_tabular_form_for :time_entry, @time_entry, :url => {:action => 'edit', :id => @time_entry, :project_id => @time_entry.project} do |f| %>
|
||||
<%= error_messages_for 'time_entry' %>
|
||||
<%= back_url_hidden_field_tag %>
|
||||
|
||||
<div class="box">
|
||||
<p><%= f.text_field :issue_id, :size => 6 %> <em><%= h("#{@time_entry.issue.tracker.name} ##{@time_entry.issue.id}: #{@time_entry.issue.subject}") if @time_entry.issue %></em></p>
|
||||
<p><%= f.text_field :spent_on, :size => 10, :required => true %><%= calendar_for('time_entry_spent_on') %></p>
|
||||
<p><%= f.text_field :hours, :size => 6, :required => true %></p>
|
||||
<p><%= f.text_field :comments, :size => 100 %></p>
|
||||
<p><%= f.select :activity_id, activity_collection_for_select_options, :required => true %></p>
|
||||
<% @time_entry.custom_field_values.each do |value| %>
|
||||
<p><%= custom_field_tag_with_label :time_entry, value %></p>
|
||||
<% end %>
|
||||
<%= call_hook(:view_timelog_edit_form_bottom, { :time_entry => @time_entry, :form => f }) %>
|
||||
</div>
|
||||
|
||||
<%= submit_tag l(:button_save) %>
|
||||
|
||||
<% end %>
|
||||
<h2><%= l(:label_spent_time) %></h2>
|
||||
|
||||
<% labelled_tabular_form_for :time_entry, @time_entry, :url => {:action => 'edit', :id => @time_entry, :project_id => @time_entry.project} do |f| %>
|
||||
<%= error_messages_for 'time_entry' %>
|
||||
<%= back_url_hidden_field_tag %>
|
||||
|
||||
<div class="box">
|
||||
<p><%= f.text_field :issue_id, :size => 6 %> <em><%= h("#{@time_entry.issue.tracker.name} ##{@time_entry.issue.id}: #{@time_entry.issue.subject}") if @time_entry.issue %></em></p>
|
||||
<p><%= f.text_field :spent_on, :size => 10, :required => true %><%= calendar_for('time_entry_spent_on') %></p>
|
||||
<p><%= f.text_field :hours, :size => 6, :required => true %></p>
|
||||
<p><%= f.text_field :comments, :size => 100 %></p>
|
||||
<p><%= f.select :activity_id, activity_collection_for_select_options, :required => true %></p>
|
||||
<% @time_entry.custom_field_values.each do |value| %>
|
||||
<p><%= custom_field_tag_with_label :time_entry, value %></p>
|
||||
<% end %>
|
||||
<%= call_hook(:view_timelog_edit_form_bottom, { :time_entry => @time_entry, :form => f }) %>
|
||||
</div>
|
||||
|
||||
<%= submit_tag l(:button_save) %>
|
||||
|
||||
<% end %>
|
||||
|
|
|
@ -821,20 +821,20 @@ bs:
|
|||
label_descending: Opadajuće
|
||||
label_greater_or_equal: ">="
|
||||
label_less_or_equal: <=
|
||||
text_wiki_page_destroy_question: This page has {{descendants}} child page(s) and descendant(s). What do you want to do?
|
||||
text_wiki_page_reassign_children: Reassign child pages to this parent page
|
||||
text_wiki_page_nullify_children: Keep child pages as root pages
|
||||
text_wiki_page_destroy_children: Delete child pages and all their descendants
|
||||
setting_password_min_length: Minimum password length
|
||||
field_group_by: Group results by
|
||||
mail_subject_wiki_content_updated: "'{{page}}' wiki page has been updated"
|
||||
label_wiki_content_added: Wiki page added
|
||||
mail_subject_wiki_content_added: "'{{page}}' wiki page has been added"
|
||||
mail_body_wiki_content_added: The '{{page}}' wiki page has been added by {{author}}.
|
||||
label_wiki_content_updated: Wiki page updated
|
||||
mail_body_wiki_content_updated: The '{{page}}' wiki page has been updated by {{author}}.
|
||||
permission_add_project: Create project
|
||||
setting_new_project_user_role_id: Role given to a non-admin user who creates a project
|
||||
text_wiki_page_destroy_question: This page has {{descendants}} child page(s) and descendant(s). What do you want to do?
|
||||
text_wiki_page_reassign_children: Reassign child pages to this parent page
|
||||
text_wiki_page_nullify_children: Keep child pages as root pages
|
||||
text_wiki_page_destroy_children: Delete child pages and all their descendants
|
||||
setting_password_min_length: Minimum password length
|
||||
field_group_by: Group results by
|
||||
mail_subject_wiki_content_updated: "'{{page}}' wiki page has been updated"
|
||||
label_wiki_content_added: Wiki page added
|
||||
mail_subject_wiki_content_added: "'{{page}}' wiki page has been added"
|
||||
mail_body_wiki_content_added: The '{{page}}' wiki page has been added by {{author}}.
|
||||
label_wiki_content_updated: Wiki page updated
|
||||
mail_body_wiki_content_updated: The '{{page}}' wiki page has been updated by {{author}}.
|
||||
permission_add_project: Create project
|
||||
setting_new_project_user_role_id: Role given to a non-admin user who creates a project
|
||||
label_view_all_revisions: View all revisions
|
||||
label_tag: Tag
|
||||
label_branch: Branch
|
||||
|
@ -843,7 +843,7 @@ bs:
|
|||
text_journal_changed: "{{label}} changed from {{old}} to {{new}}"
|
||||
text_journal_set_to: "{{label}} set to {{value}}"
|
||||
text_journal_deleted: "{{label}} deleted"
|
||||
label_group_plural: Groups
|
||||
label_group: Group
|
||||
label_group_new: New group
|
||||
label_time_entry_plural: Spent time
|
||||
label_group_plural: Groups
|
||||
label_group: Group
|
||||
label_group_new: New group
|
||||
label_time_entry_plural: Spent time
|
||||
|
|
|
@ -825,7 +825,7 @@ el:
|
|||
text_journal_changed: "{{label}} changed from {{old}} to {{new}}"
|
||||
text_journal_set_to: "{{label}} set to {{value}}"
|
||||
text_journal_deleted: "{{label}} deleted"
|
||||
label_group_plural: Groups
|
||||
label_group: Group
|
||||
label_group_new: New group
|
||||
label_time_entry_plural: Spent time
|
||||
label_group_plural: Groups
|
||||
label_group: Group
|
||||
label_group_new: New group
|
||||
label_time_entry_plural: Spent time
|
||||
|
|
|
@ -1,124 +1,124 @@
|
|||
---
|
||||
attachments_001:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: text/plain
|
||||
disk_filename: 060719210727_error281.txt
|
||||
container_id: 3
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 1
|
||||
container_type: Issue
|
||||
filesize: 28
|
||||
filename: error281.txt
|
||||
author_id: 2
|
||||
attachments_002:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: text/plain
|
||||
disk_filename: 060719210727_document.txt
|
||||
container_id: 1
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 2
|
||||
container_type: Document
|
||||
filesize: 28
|
||||
filename: document.txt
|
||||
author_id: 2
|
||||
attachments_003:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: image/gif
|
||||
disk_filename: 060719210727_logo.gif
|
||||
container_id: 4
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 3
|
||||
container_type: WikiPage
|
||||
filesize: 280
|
||||
filename: logo.gif
|
||||
description: This is a logo
|
||||
author_id: 2
|
||||
attachments_004:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_source.rb
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 4
|
||||
filesize: 153
|
||||
filename: source.rb
|
||||
author_id: 2
|
||||
description: This is a Ruby source file
|
||||
content_type: application/x-ruby
|
||||
attachments_005:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_changeset.diff
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 5
|
||||
filesize: 687
|
||||
filename: changeset.diff
|
||||
author_id: 2
|
||||
content_type: text/x-diff
|
||||
attachments_006:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_archive.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 6
|
||||
filesize: 157
|
||||
filename: archive.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_007:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 4
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_archive.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 7
|
||||
filesize: 157
|
||||
filename: archive.zip
|
||||
author_id: 1
|
||||
content_type: application/octet-stream
|
||||
attachments_008:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Project
|
||||
container_id: 1
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_project_file.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 8
|
||||
filesize: 320
|
||||
filename: project_file.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_009:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Version
|
||||
container_id: 1
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_version_file.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 9
|
||||
filesize: 452
|
||||
filename: version_file.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_010:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 2
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_picture.jpg
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 10
|
||||
filesize: 452
|
||||
filename: picture.jpg
|
||||
author_id: 2
|
||||
content_type: image/jpeg
|
||||
---
|
||||
attachments_001:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: text/plain
|
||||
disk_filename: 060719210727_error281.txt
|
||||
container_id: 3
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 1
|
||||
container_type: Issue
|
||||
filesize: 28
|
||||
filename: error281.txt
|
||||
author_id: 2
|
||||
attachments_002:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: text/plain
|
||||
disk_filename: 060719210727_document.txt
|
||||
container_id: 1
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 2
|
||||
container_type: Document
|
||||
filesize: 28
|
||||
filename: document.txt
|
||||
author_id: 2
|
||||
attachments_003:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
downloads: 0
|
||||
content_type: image/gif
|
||||
disk_filename: 060719210727_logo.gif
|
||||
container_id: 4
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 3
|
||||
container_type: WikiPage
|
||||
filesize: 280
|
||||
filename: logo.gif
|
||||
description: This is a logo
|
||||
author_id: 2
|
||||
attachments_004:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_source.rb
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 4
|
||||
filesize: 153
|
||||
filename: source.rb
|
||||
author_id: 2
|
||||
description: This is a Ruby source file
|
||||
content_type: application/x-ruby
|
||||
attachments_005:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_changeset.diff
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 5
|
||||
filesize: 687
|
||||
filename: changeset.diff
|
||||
author_id: 2
|
||||
content_type: text/x-diff
|
||||
attachments_006:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 3
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_archive.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 6
|
||||
filesize: 157
|
||||
filename: archive.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_007:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 4
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_archive.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 7
|
||||
filesize: 157
|
||||
filename: archive.zip
|
||||
author_id: 1
|
||||
content_type: application/octet-stream
|
||||
attachments_008:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Project
|
||||
container_id: 1
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_project_file.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 8
|
||||
filesize: 320
|
||||
filename: project_file.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_009:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Version
|
||||
container_id: 1
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_version_file.zip
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 9
|
||||
filesize: 452
|
||||
filename: version_file.zip
|
||||
author_id: 2
|
||||
content_type: application/octet-stream
|
||||
attachments_010:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
container_type: Issue
|
||||
container_id: 2
|
||||
downloads: 0
|
||||
disk_filename: 060719210727_picture.jpg
|
||||
digest: b91e08d0cf966d5c6ff411bd8c4cc3a2
|
||||
id: 10
|
||||
filesize: 452
|
||||
filename: picture.jpg
|
||||
author_id: 2
|
||||
content_type: image/jpeg
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
--- {}
|
||||
|
||||
--- {}
|
||||
|
||||
|
|
|
@ -1,19 +1,19 @@
|
|||
---
|
||||
boards_001:
|
||||
name: Help
|
||||
project_id: 1
|
||||
topics_count: 2
|
||||
id: 1
|
||||
description: Help board
|
||||
position: 1
|
||||
last_message_id: 6
|
||||
messages_count: 6
|
||||
boards_002:
|
||||
name: Discussion
|
||||
project_id: 1
|
||||
topics_count: 0
|
||||
id: 2
|
||||
description: Discussion board
|
||||
position: 2
|
||||
last_message_id:
|
||||
messages_count: 0
|
||||
---
|
||||
boards_001:
|
||||
name: Help
|
||||
project_id: 1
|
||||
topics_count: 2
|
||||
id: 1
|
||||
description: Help board
|
||||
position: 1
|
||||
last_message_id: 6
|
||||
messages_count: 6
|
||||
boards_002:
|
||||
name: Discussion
|
||||
project_id: 1
|
||||
topics_count: 0
|
||||
id: 2
|
||||
description: Discussion board
|
||||
position: 2
|
||||
last_message_id:
|
||||
messages_count: 0
|
||||
|
|
|
@ -1,23 +1,23 @@
|
|||
---
|
||||
changes_001:
|
||||
id: 1
|
||||
changeset_id: 100
|
||||
action: A
|
||||
path: /test/some/path/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
changes_002:
|
||||
id: 2
|
||||
changeset_id: 100
|
||||
action: A
|
||||
path: /test/some/path/elsewhere/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
changes_003:
|
||||
id: 3
|
||||
changeset_id: 101
|
||||
action: M
|
||||
path: /test/some/path/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
---
|
||||
changes_001:
|
||||
id: 1
|
||||
changeset_id: 100
|
||||
action: A
|
||||
path: /test/some/path/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
changes_002:
|
||||
id: 2
|
||||
changeset_id: 100
|
||||
action: A
|
||||
path: /test/some/path/elsewhere/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
changes_003:
|
||||
id: 3
|
||||
changeset_id: 101
|
||||
action: M
|
||||
path: /test/some/path/in/the/repo
|
||||
from_path:
|
||||
from_revision:
|
||||
|
|
@ -1,84 +1,84 @@
|
|||
---
|
||||
changesets_001:
|
||||
commit_date: 2007-04-11
|
||||
committed_on: 2007-04-11 15:14:44 +02:00
|
||||
revision: 1
|
||||
id: 100
|
||||
comments: My very first commit
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_002:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 2
|
||||
id: 101
|
||||
comments: 'This commit fixes #1, #2 and references #1 & #3'
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_003:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 3
|
||||
id: 102
|
||||
comments: |-
|
||||
A commit with wrong issue ids
|
||||
IssueID 666 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_004:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 4
|
||||
id: 103
|
||||
comments: |-
|
||||
A commit with an issue id of an other project
|
||||
IssueID 4 2
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_005:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Modified one file in the folder.
|
||||
committed_on: 2007-09-10 19:01:08
|
||||
revision: "5"
|
||||
id: 104
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_006:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Moved helloworld.rb from / to /folder.
|
||||
committed_on: 2007-09-10 19:01:47
|
||||
revision: "6"
|
||||
id: 105
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_007:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Removed one file.
|
||||
committed_on: 2007-09-10 19:02:16
|
||||
revision: "7"
|
||||
id: 106
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_008:
|
||||
commit_date: "2007-09-10"
|
||||
comments: |-
|
||||
This commits references an issue.
|
||||
Refs #2
|
||||
committed_on: 2007-09-10 19:04:35
|
||||
revision: "8"
|
||||
id: 107
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
---
|
||||
changesets_001:
|
||||
commit_date: 2007-04-11
|
||||
committed_on: 2007-04-11 15:14:44 +02:00
|
||||
revision: 1
|
||||
id: 100
|
||||
comments: My very first commit
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_002:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 2
|
||||
id: 101
|
||||
comments: 'This commit fixes #1, #2 and references #1 & #3'
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_003:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 3
|
||||
id: 102
|
||||
comments: |-
|
||||
A commit with wrong issue ids
|
||||
IssueID 666 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_004:
|
||||
commit_date: 2007-04-12
|
||||
committed_on: 2007-04-12 15:14:44 +02:00
|
||||
revision: 4
|
||||
id: 103
|
||||
comments: |-
|
||||
A commit with an issue id of an other project
|
||||
IssueID 4 2
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
user_id: 3
|
||||
changesets_005:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Modified one file in the folder.
|
||||
committed_on: 2007-09-10 19:01:08
|
||||
revision: "5"
|
||||
id: 104
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_006:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Moved helloworld.rb from / to /folder.
|
||||
committed_on: 2007-09-10 19:01:47
|
||||
revision: "6"
|
||||
id: 105
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_007:
|
||||
commit_date: "2007-09-10"
|
||||
comments: Removed one file.
|
||||
committed_on: 2007-09-10 19:02:16
|
||||
revision: "7"
|
||||
id: 106
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
changesets_008:
|
||||
commit_date: "2007-09-10"
|
||||
comments: |-
|
||||
This commits references an issue.
|
||||
Refs #2
|
||||
committed_on: 2007-09-10 19:04:35
|
||||
revision: "8"
|
||||
id: 107
|
||||
scmid:
|
||||
user_id: 3
|
||||
repository_id: 10
|
||||
committer: dlopper
|
||||
|
|
@ -1,90 +1,90 @@
|
|||
---
|
||||
custom_fields_001:
|
||||
name: Database
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
is_filter: true
|
||||
type: IssueCustomField
|
||||
max_length: 0
|
||||
possible_values:
|
||||
- MySQL
|
||||
- PostgreSQL
|
||||
- Oracle
|
||||
id: 1
|
||||
is_required: false
|
||||
field_format: list
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_002:
|
||||
name: Searchable field
|
||||
min_length: 1
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
type: IssueCustomField
|
||||
max_length: 100
|
||||
possible_values: ""
|
||||
id: 2
|
||||
is_required: false
|
||||
field_format: string
|
||||
searchable: true
|
||||
default_value: "Default string"
|
||||
editable: true
|
||||
custom_fields_003:
|
||||
name: Development status
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
is_filter: true
|
||||
type: ProjectCustomField
|
||||
max_length: 0
|
||||
possible_values:
|
||||
- Stable
|
||||
- Beta
|
||||
- Alpha
|
||||
- Planning
|
||||
id: 3
|
||||
is_required: true
|
||||
field_format: list
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_004:
|
||||
name: Phone number
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
type: UserCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 4
|
||||
is_required: false
|
||||
field_format: string
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_005:
|
||||
name: Money
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
type: UserCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 5
|
||||
is_required: false
|
||||
field_format: float
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_006:
|
||||
name: Float field
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
type: IssueCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 6
|
||||
is_required: false
|
||||
field_format: float
|
||||
default_value: ""
|
||||
editable: true
|
||||
---
|
||||
custom_fields_001:
|
||||
name: Database
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
is_filter: true
|
||||
type: IssueCustomField
|
||||
max_length: 0
|
||||
possible_values:
|
||||
- MySQL
|
||||
- PostgreSQL
|
||||
- Oracle
|
||||
id: 1
|
||||
is_required: false
|
||||
field_format: list
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_002:
|
||||
name: Searchable field
|
||||
min_length: 1
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
type: IssueCustomField
|
||||
max_length: 100
|
||||
possible_values: ""
|
||||
id: 2
|
||||
is_required: false
|
||||
field_format: string
|
||||
searchable: true
|
||||
default_value: "Default string"
|
||||
editable: true
|
||||
custom_fields_003:
|
||||
name: Development status
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
is_filter: true
|
||||
type: ProjectCustomField
|
||||
max_length: 0
|
||||
possible_values:
|
||||
- Stable
|
||||
- Beta
|
||||
- Alpha
|
||||
- Planning
|
||||
id: 3
|
||||
is_required: true
|
||||
field_format: list
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_004:
|
||||
name: Phone number
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
type: UserCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 4
|
||||
is_required: false
|
||||
field_format: string
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_005:
|
||||
name: Money
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: false
|
||||
type: UserCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 5
|
||||
is_required: false
|
||||
field_format: float
|
||||
default_value: ""
|
||||
editable: true
|
||||
custom_fields_006:
|
||||
name: Float field
|
||||
min_length: 0
|
||||
regexp: ""
|
||||
is_for_all: true
|
||||
type: IssueCustomField
|
||||
max_length: 0
|
||||
possible_values: ""
|
||||
id: 6
|
||||
is_required: false
|
||||
field_format: float
|
||||
default_value: ""
|
||||
editable: true
|
||||
|
|
@ -1,2 +1,2 @@
|
|||
--- {}
|
||||
|
||||
--- {}
|
||||
|
||||
|
|
|
@ -1,19 +1,19 @@
|
|||
---
|
||||
custom_fields_trackers_001:
|
||||
custom_field_id: 1
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_002:
|
||||
custom_field_id: 2
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_003:
|
||||
custom_field_id: 2
|
||||
tracker_id: 3
|
||||
custom_fields_trackers_004:
|
||||
custom_field_id: 6
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_005:
|
||||
custom_field_id: 6
|
||||
tracker_id: 2
|
||||
custom_fields_trackers_006:
|
||||
custom_field_id: 6
|
||||
tracker_id: 3
|
||||
---
|
||||
custom_fields_trackers_001:
|
||||
custom_field_id: 1
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_002:
|
||||
custom_field_id: 2
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_003:
|
||||
custom_field_id: 2
|
||||
tracker_id: 3
|
||||
custom_fields_trackers_004:
|
||||
custom_field_id: 6
|
||||
tracker_id: 1
|
||||
custom_fields_trackers_005:
|
||||
custom_field_id: 6
|
||||
tracker_id: 2
|
||||
custom_fields_trackers_006:
|
||||
custom_field_id: 6
|
||||
tracker_id: 3
|
||||
|
|
|
@ -1,86 +1,86 @@
|
|||
---
|
||||
custom_values_006:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 3
|
||||
id: 6
|
||||
value: "125"
|
||||
custom_values_007:
|
||||
customized_type: Project
|
||||
custom_field_id: 3
|
||||
customized_id: 1
|
||||
id: 7
|
||||
value: Stable
|
||||
custom_values_001:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 3
|
||||
id: 1
|
||||
value: ""
|
||||
custom_values_002:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 4
|
||||
id: 2
|
||||
value: 01 23 45 67 89
|
||||
custom_values_003:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 2
|
||||
id: 3
|
||||
value: ""
|
||||
custom_values_004:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 1
|
||||
id: 4
|
||||
value: "125"
|
||||
custom_values_005:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 2
|
||||
id: 5
|
||||
value: ""
|
||||
custom_values_008:
|
||||
customized_type: Issue
|
||||
custom_field_id: 1
|
||||
customized_id: 3
|
||||
id: 8
|
||||
value: "MySQL"
|
||||
custom_values_009:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 3
|
||||
id: 9
|
||||
value: "this is a stringforcustomfield search"
|
||||
custom_values_010:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 1
|
||||
id: 10
|
||||
value: "2.1"
|
||||
custom_values_011:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 2
|
||||
id: 11
|
||||
value: "2.05"
|
||||
custom_values_012:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 3
|
||||
id: 12
|
||||
value: "11.65"
|
||||
custom_values_013:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 7
|
||||
id: 13
|
||||
value: ""
|
||||
custom_values_014:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 5
|
||||
id: 14
|
||||
value: "-7.6"
|
||||
---
|
||||
custom_values_006:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 3
|
||||
id: 6
|
||||
value: "125"
|
||||
custom_values_007:
|
||||
customized_type: Project
|
||||
custom_field_id: 3
|
||||
customized_id: 1
|
||||
id: 7
|
||||
value: Stable
|
||||
custom_values_001:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 3
|
||||
id: 1
|
||||
value: ""
|
||||
custom_values_002:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 4
|
||||
id: 2
|
||||
value: 01 23 45 67 89
|
||||
custom_values_003:
|
||||
customized_type: User
|
||||
custom_field_id: 4
|
||||
customized_id: 2
|
||||
id: 3
|
||||
value: ""
|
||||
custom_values_004:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 1
|
||||
id: 4
|
||||
value: "125"
|
||||
custom_values_005:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 2
|
||||
id: 5
|
||||
value: ""
|
||||
custom_values_008:
|
||||
customized_type: Issue
|
||||
custom_field_id: 1
|
||||
customized_id: 3
|
||||
id: 8
|
||||
value: "MySQL"
|
||||
custom_values_009:
|
||||
customized_type: Issue
|
||||
custom_field_id: 2
|
||||
customized_id: 3
|
||||
id: 9
|
||||
value: "this is a stringforcustomfield search"
|
||||
custom_values_010:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 1
|
||||
id: 10
|
||||
value: "2.1"
|
||||
custom_values_011:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 2
|
||||
id: 11
|
||||
value: "2.05"
|
||||
custom_values_012:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 3
|
||||
id: 12
|
||||
value: "11.65"
|
||||
custom_values_013:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 7
|
||||
id: 13
|
||||
value: ""
|
||||
custom_values_014:
|
||||
customized_type: Issue
|
||||
custom_field_id: 6
|
||||
customized_id: 5
|
||||
id: 14
|
||||
value: "-7.6"
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
documents_001:
|
||||
created_on: 2007-01-27 15:08:27 +01:00
|
||||
project_id: 1
|
||||
title: "Test document"
|
||||
id: 1
|
||||
description: "Document description"
|
||||
documents_001:
|
||||
created_on: 2007-01-27 15:08:27 +01:00
|
||||
project_id: 1
|
||||
title: "Test document"
|
||||
id: 1
|
||||
description: "Document description"
|
||||
category_id: 1
|
|
@ -1,69 +1,69 @@
|
|||
---
|
||||
enumerations_001:
|
||||
name: Uncategorized
|
||||
id: 1
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_002:
|
||||
name: User documentation
|
||||
id: 2
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_003:
|
||||
name: Technical documentation
|
||||
id: 3
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_004:
|
||||
name: Low
|
||||
id: 4
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_005:
|
||||
name: Normal
|
||||
id: 5
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
is_default: true
|
||||
enumerations_006:
|
||||
name: High
|
||||
id: 6
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_007:
|
||||
name: Urgent
|
||||
id: 7
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_008:
|
||||
name: Immediate
|
||||
id: 8
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_009:
|
||||
name: Design
|
||||
id: 9
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
enumerations_010:
|
||||
name: Development
|
||||
id: 10
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
is_default: true
|
||||
enumerations_011:
|
||||
name: QA
|
||||
id: 11
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
enumerations_012:
|
||||
name: Default Enumeration
|
||||
id: 12
|
||||
opt: ''
|
||||
type: Enumeration
|
||||
is_default: true
|
||||
enumerations_013:
|
||||
name: Another Enumeration
|
||||
id: 13
|
||||
opt: ''
|
||||
type: Enumeration
|
||||
---
|
||||
enumerations_001:
|
||||
name: Uncategorized
|
||||
id: 1
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_002:
|
||||
name: User documentation
|
||||
id: 2
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_003:
|
||||
name: Technical documentation
|
||||
id: 3
|
||||
opt: DCAT
|
||||
type: DocumentCategory
|
||||
enumerations_004:
|
||||
name: Low
|
||||
id: 4
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_005:
|
||||
name: Normal
|
||||
id: 5
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
is_default: true
|
||||
enumerations_006:
|
||||
name: High
|
||||
id: 6
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_007:
|
||||
name: Urgent
|
||||
id: 7
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_008:
|
||||
name: Immediate
|
||||
id: 8
|
||||
opt: IPRI
|
||||
type: IssuePriority
|
||||
enumerations_009:
|
||||
name: Design
|
||||
id: 9
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
enumerations_010:
|
||||
name: Development
|
||||
id: 10
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
is_default: true
|
||||
enumerations_011:
|
||||
name: QA
|
||||
id: 11
|
||||
opt: ACTI
|
||||
type: TimeEntryActivity
|
||||
enumerations_012:
|
||||
name: Default Enumeration
|
||||
id: 12
|
||||
opt: ''
|
||||
type: Enumeration
|
||||
is_default: true
|
||||
enumerations_013:
|
||||
name: Another Enumeration
|
||||
id: 13
|
||||
opt: ''
|
||||
type: Enumeration
|
||||
|
|
|
@ -1,22 +1,22 @@
|
|||
---
|
||||
issue_categories_001:
|
||||
name: Printing
|
||||
project_id: 1
|
||||
assigned_to_id: 2
|
||||
id: 1
|
||||
issue_categories_002:
|
||||
name: Recipes
|
||||
project_id: 1
|
||||
assigned_to_id:
|
||||
id: 2
|
||||
issue_categories_003:
|
||||
name: Stock management
|
||||
project_id: 2
|
||||
assigned_to_id:
|
||||
id: 3
|
||||
issue_categories_004:
|
||||
name: Printing
|
||||
project_id: 2
|
||||
assigned_to_id:
|
||||
id: 4
|
||||
---
|
||||
issue_categories_001:
|
||||
name: Printing
|
||||
project_id: 1
|
||||
assigned_to_id: 2
|
||||
id: 1
|
||||
issue_categories_002:
|
||||
name: Recipes
|
||||
project_id: 1
|
||||
assigned_to_id:
|
||||
id: 2
|
||||
issue_categories_003:
|
||||
name: Stock management
|
||||
project_id: 2
|
||||
assigned_to_id:
|
||||
id: 3
|
||||
issue_categories_004:
|
||||
name: Printing
|
||||
project_id: 2
|
||||
assigned_to_id:
|
||||
id: 4
|
||||
|
|
@ -1,31 +1,31 @@
|
|||
---
|
||||
issue_statuses_006:
|
||||
name: Rejected
|
||||
is_default: false
|
||||
is_closed: true
|
||||
id: 6
|
||||
issue_statuses_001:
|
||||
name: New
|
||||
is_default: true
|
||||
is_closed: false
|
||||
id: 1
|
||||
issue_statuses_002:
|
||||
name: Assigned
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 2
|
||||
issue_statuses_003:
|
||||
name: Resolved
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 3
|
||||
issue_statuses_004:
|
||||
name: Feedback
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 4
|
||||
issue_statuses_005:
|
||||
name: Closed
|
||||
is_default: false
|
||||
is_closed: true
|
||||
id: 5
|
||||
---
|
||||
issue_statuses_006:
|
||||
name: Rejected
|
||||
is_default: false
|
||||
is_closed: true
|
||||
id: 6
|
||||
issue_statuses_001:
|
||||
name: New
|
||||
is_default: true
|
||||
is_closed: false
|
||||
id: 1
|
||||
issue_statuses_002:
|
||||
name: Assigned
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 2
|
||||
issue_statuses_003:
|
||||
name: Resolved
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 3
|
||||
issue_statuses_004:
|
||||
name: Feedback
|
||||
is_default: false
|
||||
is_closed: false
|
||||
id: 4
|
||||
issue_statuses_005:
|
||||
name: Closed
|
||||
is_default: false
|
||||
is_closed: true
|
||||
id: 5
|
||||
|
|
|
@ -1,159 +1,159 @@
|
|||
---
|
||||
issues_001:
|
||||
created_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 1.day.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Can't print recipes
|
||||
id: 1
|
||||
fixed_version_id:
|
||||
category_id: 1
|
||||
description: Unable to print recipes
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 1.day.ago.to_date.to_s(:db) %>
|
||||
due_date: <%= 10.day.from_now.to_date.to_s(:db) %>
|
||||
issues_002:
|
||||
created_on: 2006-07-19 21:04:21 +02:00
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:09:50 +02:00
|
||||
priority_id: 5
|
||||
subject: Add ingredients categories
|
||||
id: 2
|
||||
fixed_version_id: 2
|
||||
category_id:
|
||||
description: Ingredients of the recipe should be classified by categories
|
||||
tracker_id: 2
|
||||
assigned_to_id: 3
|
||||
author_id: 2
|
||||
status_id: 2
|
||||
start_date: <%= 2.day.ago.to_date.to_s(:db) %>
|
||||
due_date:
|
||||
issues_003:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:07:27 +02:00
|
||||
priority_id: 4
|
||||
subject: Error 281 when updating a recipe
|
||||
id: 3
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: Error 281 is encountered when saving a recipe
|
||||
tracker_id: 1
|
||||
assigned_to_id: 3
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 1.day.from_now.to_date.to_s(:db) %>
|
||||
due_date: <%= 40.day.ago.to_date.to_s(:db) %>
|
||||
issues_004:
|
||||
created_on: <%= 5.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 2
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Issue on project 2
|
||||
id: 4
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: Issue on project 2
|
||||
tracker_id: 1
|
||||
assigned_to_id: 2
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
issues_005:
|
||||
created_on: <%= 5.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 3
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Subproject issue
|
||||
id: 5
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue on a cookbook subproject
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
issues_006:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Issue of a private subproject
|
||||
id: 6
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue of a private subproject of cookbook
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
issues_007:
|
||||
created_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Issue due today
|
||||
id: 7
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that is due today
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 10.days.ago.to_s(:db) %>
|
||||
due_date: <%= Date.today.to_s(:db) %>
|
||||
lock_version: 0
|
||||
issues_008:
|
||||
created_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Closed issue
|
||||
id: 8
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is a closed issue.
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 5
|
||||
start_date:
|
||||
due_date:
|
||||
lock_version: 0
|
||||
issues_009:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Blocked Issue
|
||||
id: 9
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that is blocked by issue #10
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
issues_010:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Issue Doing the Blocking
|
||||
id: 10
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that blocks issue #9
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
---
|
||||
issues_001:
|
||||
created_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 1.day.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Can't print recipes
|
||||
id: 1
|
||||
fixed_version_id:
|
||||
category_id: 1
|
||||
description: Unable to print recipes
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 1.day.ago.to_date.to_s(:db) %>
|
||||
due_date: <%= 10.day.from_now.to_date.to_s(:db) %>
|
||||
issues_002:
|
||||
created_on: 2006-07-19 21:04:21 +02:00
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:09:50 +02:00
|
||||
priority_id: 5
|
||||
subject: Add ingredients categories
|
||||
id: 2
|
||||
fixed_version_id: 2
|
||||
category_id:
|
||||
description: Ingredients of the recipe should be classified by categories
|
||||
tracker_id: 2
|
||||
assigned_to_id: 3
|
||||
author_id: 2
|
||||
status_id: 2
|
||||
start_date: <%= 2.day.ago.to_date.to_s(:db) %>
|
||||
due_date:
|
||||
issues_003:
|
||||
created_on: 2006-07-19 21:07:27 +02:00
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:07:27 +02:00
|
||||
priority_id: 4
|
||||
subject: Error 281 when updating a recipe
|
||||
id: 3
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: Error 281 is encountered when saving a recipe
|
||||
tracker_id: 1
|
||||
assigned_to_id: 3
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 1.day.from_now.to_date.to_s(:db) %>
|
||||
due_date: <%= 40.day.ago.to_date.to_s(:db) %>
|
||||
issues_004:
|
||||
created_on: <%= 5.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 2
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Issue on project 2
|
||||
id: 4
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: Issue on project 2
|
||||
tracker_id: 1
|
||||
assigned_to_id: 2
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
issues_005:
|
||||
created_on: <%= 5.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 3
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Subproject issue
|
||||
id: 5
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue on a cookbook subproject
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
issues_006:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 4
|
||||
subject: Issue of a private subproject
|
||||
id: 6
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue of a private subproject of cookbook
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
issues_007:
|
||||
created_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Issue due today
|
||||
id: 7
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that is due today
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= 10.days.ago.to_s(:db) %>
|
||||
due_date: <%= Date.today.to_s(:db) %>
|
||||
lock_version: 0
|
||||
issues_008:
|
||||
created_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
project_id: 1
|
||||
updated_on: <%= 10.days.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Closed issue
|
||||
id: 8
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is a closed issue.
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 5
|
||||
start_date:
|
||||
due_date:
|
||||
lock_version: 0
|
||||
issues_009:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Blocked Issue
|
||||
id: 9
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that is blocked by issue #10
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
issues_010:
|
||||
created_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
project_id: 5
|
||||
updated_on: <%= 1.minute.ago.to_date.to_s(:db) %>
|
||||
priority_id: 5
|
||||
subject: Issue Doing the Blocking
|
||||
id: 10
|
||||
fixed_version_id:
|
||||
category_id:
|
||||
description: This is an issue that blocks issue #9
|
||||
tracker_id: 1
|
||||
assigned_to_id:
|
||||
author_id: 2
|
||||
status_id: 1
|
||||
start_date: <%= Date.today.to_s(:db) %>
|
||||
due_date: <%= 1.days.from_now.to_date.to_s(:db) %>
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
---
|
||||
journal_details_001:
|
||||
old_value: "1"
|
||||
property: attr
|
||||
id: 1
|
||||
value: "2"
|
||||
prop_key: status_id
|
||||
journal_id: 1
|
||||
journal_details_002:
|
||||
old_value: "40"
|
||||
property: attr
|
||||
id: 2
|
||||
value: "30"
|
||||
prop_key: done_ratio
|
||||
journal_id: 1
|
||||
---
|
||||
journal_details_001:
|
||||
old_value: "1"
|
||||
property: attr
|
||||
id: 1
|
||||
value: "2"
|
||||
prop_key: status_id
|
||||
journal_id: 1
|
||||
journal_details_002:
|
||||
old_value: "40"
|
||||
property: attr
|
||||
id: 2
|
||||
value: "30"
|
||||
prop_key: done_ratio
|
||||
journal_id: 1
|
||||
|
|
|
@ -1,23 +1,23 @@
|
|||
---
|
||||
journals_001:
|
||||
created_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
notes: "Journal notes"
|
||||
id: 1
|
||||
journalized_type: Issue
|
||||
user_id: 1
|
||||
journalized_id: 1
|
||||
journals_002:
|
||||
created_on: <%= 1.days.ago.to_date.to_s(:db) %>
|
||||
notes: "Some notes with Redmine links: #2, r2."
|
||||
id: 2
|
||||
journalized_type: Issue
|
||||
user_id: 2
|
||||
journalized_id: 1
|
||||
journals_003:
|
||||
created_on: <%= 1.days.ago.to_date.to_s(:db) %>
|
||||
notes: "A comment with inline image: !picture.jpg!"
|
||||
id: 3
|
||||
journalized_type: Issue
|
||||
user_id: 2
|
||||
journalized_id: 2
|
||||
---
|
||||
journals_001:
|
||||
created_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
notes: "Journal notes"
|
||||
id: 1
|
||||
journalized_type: Issue
|
||||
user_id: 1
|
||||
journalized_id: 1
|
||||
journals_002:
|
||||
created_on: <%= 1.days.ago.to_date.to_s(:db) %>
|
||||
notes: "Some notes with Redmine links: #2, r2."
|
||||
id: 2
|
||||
journalized_type: Issue
|
||||
user_id: 2
|
||||
journalized_id: 1
|
||||
journals_003:
|
||||
created_on: <%= 1.days.ago.to_date.to_s(:db) %>
|
||||
notes: "A comment with inline image: !picture.jpg!"
|
||||
id: 3
|
||||
journalized_type: Issue
|
||||
user_id: 2
|
||||
journalized_id: 2
|
||||
|
|
@ -1,45 +1,45 @@
|
|||
---
|
||||
members_001:
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 1
|
||||
id: 1
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_002:
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 1
|
||||
id: 2
|
||||
user_id: 3
|
||||
mail_notification: true
|
||||
members_003:
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 2
|
||||
id: 3
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_004:
|
||||
id: 4
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 1
|
||||
# Locked user
|
||||
user_id: 5
|
||||
mail_notification: true
|
||||
members_005:
|
||||
id: 5
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_006:
|
||||
id: 6
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 10
|
||||
mail_notification: false
|
||||
members_007:
|
||||
id: 7
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 8
|
||||
mail_notification: false
|
||||
---
|
||||
members_001:
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 1
|
||||
id: 1
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_002:
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 1
|
||||
id: 2
|
||||
user_id: 3
|
||||
mail_notification: true
|
||||
members_003:
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 2
|
||||
id: 3
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_004:
|
||||
id: 4
|
||||
created_on: 2006-07-19 19:35:36 +02:00
|
||||
project_id: 1
|
||||
# Locked user
|
||||
user_id: 5
|
||||
mail_notification: true
|
||||
members_005:
|
||||
id: 5
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 2
|
||||
mail_notification: true
|
||||
members_006:
|
||||
id: 6
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 10
|
||||
mail_notification: false
|
||||
members_007:
|
||||
id: 7
|
||||
created_on: 2006-07-19 19:35:33 +02:00
|
||||
project_id: 5
|
||||
user_id: 8
|
||||
mail_notification: false
|
||||
|
|
@ -1,68 +1,68 @@
|
|||
---
|
||||
messages_001:
|
||||
created_on: 2007-05-12 17:15:32 +02:00
|
||||
updated_on: 2007-05-12 17:15:32 +02:00
|
||||
subject: First post
|
||||
id: 1
|
||||
replies_count: 2
|
||||
last_reply_id: 3
|
||||
content: "This is the very first post\n\
|
||||
in the forum"
|
||||
author_id: 1
|
||||
parent_id:
|
||||
board_id: 1
|
||||
messages_002:
|
||||
created_on: 2007-05-12 17:18:00 +02:00
|
||||
updated_on: 2007-05-12 17:18:00 +02:00
|
||||
subject: First reply
|
||||
id: 2
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Reply to the first post"
|
||||
author_id: 1
|
||||
parent_id: 1
|
||||
board_id: 1
|
||||
messages_003:
|
||||
created_on: 2007-05-12 17:18:02 +02:00
|
||||
updated_on: 2007-05-12 17:18:02 +02:00
|
||||
subject: "RE: First post"
|
||||
id: 3
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "An other reply"
|
||||
author_id: 2
|
||||
parent_id: 1
|
||||
board_id: 1
|
||||
messages_004:
|
||||
created_on: 2007-08-12 17:15:32 +02:00
|
||||
updated_on: 2007-08-12 17:15:32 +02:00
|
||||
subject: Post 2
|
||||
id: 4
|
||||
replies_count: 2
|
||||
last_reply_id: 6
|
||||
content: "This is an other post"
|
||||
author_id:
|
||||
parent_id:
|
||||
board_id: 1
|
||||
messages_005:
|
||||
created_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
updated_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
subject: 'RE: post 2'
|
||||
id: 5
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Reply to the second post"
|
||||
author_id: 1
|
||||
parent_id: 4
|
||||
board_id: 1
|
||||
messages_006:
|
||||
created_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
subject: 'RE: post 2'
|
||||
id: 6
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Another reply to the second post"
|
||||
author_id: 3
|
||||
parent_id: 4
|
||||
board_id: 1
|
||||
---
|
||||
messages_001:
|
||||
created_on: 2007-05-12 17:15:32 +02:00
|
||||
updated_on: 2007-05-12 17:15:32 +02:00
|
||||
subject: First post
|
||||
id: 1
|
||||
replies_count: 2
|
||||
last_reply_id: 3
|
||||
content: "This is the very first post\n\
|
||||
in the forum"
|
||||
author_id: 1
|
||||
parent_id:
|
||||
board_id: 1
|
||||
messages_002:
|
||||
created_on: 2007-05-12 17:18:00 +02:00
|
||||
updated_on: 2007-05-12 17:18:00 +02:00
|
||||
subject: First reply
|
||||
id: 2
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Reply to the first post"
|
||||
author_id: 1
|
||||
parent_id: 1
|
||||
board_id: 1
|
||||
messages_003:
|
||||
created_on: 2007-05-12 17:18:02 +02:00
|
||||
updated_on: 2007-05-12 17:18:02 +02:00
|
||||
subject: "RE: First post"
|
||||
id: 3
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "An other reply"
|
||||
author_id: 2
|
||||
parent_id: 1
|
||||
board_id: 1
|
||||
messages_004:
|
||||
created_on: 2007-08-12 17:15:32 +02:00
|
||||
updated_on: 2007-08-12 17:15:32 +02:00
|
||||
subject: Post 2
|
||||
id: 4
|
||||
replies_count: 2
|
||||
last_reply_id: 6
|
||||
content: "This is an other post"
|
||||
author_id:
|
||||
parent_id:
|
||||
board_id: 1
|
||||
messages_005:
|
||||
created_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
updated_on: <%= 3.days.ago.to_date.to_s(:db) %>
|
||||
subject: 'RE: post 2'
|
||||
id: 5
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Reply to the second post"
|
||||
author_id: 1
|
||||
parent_id: 4
|
||||
board_id: 1
|
||||
messages_006:
|
||||
created_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
updated_on: <%= 2.days.ago.to_date.to_s(:db) %>
|
||||
subject: 'RE: post 2'
|
||||
id: 6
|
||||
replies_count: 0
|
||||
last_reply_id:
|
||||
content: "Another reply to the second post"
|
||||
author_id: 3
|
||||
parent_id: 4
|
||||
board_id: 1
|
||||
|
|
|
@ -1,22 +1,22 @@
|
|||
---
|
||||
news_001:
|
||||
created_on: 2006-07-19 22:40:26 +02:00
|
||||
project_id: 1
|
||||
title: eCookbook first release !
|
||||
id: 1
|
||||
description: |-
|
||||
eCookbook 1.0 has been released.
|
||||
|
||||
Visit http://ecookbook.somenet.foo/
|
||||
summary: First version was released...
|
||||
author_id: 2
|
||||
comments_count: 1
|
||||
news_002:
|
||||
created_on: 2006-07-19 22:42:58 +02:00
|
||||
project_id: 1
|
||||
title: 100,000 downloads for eCookbook
|
||||
id: 2
|
||||
description: eCookbook 1.0 have downloaded 100,000 times
|
||||
summary: eCookbook 1.0 have downloaded 100,000 times
|
||||
author_id: 2
|
||||
comments_count: 0
|
||||
---
|
||||
news_001:
|
||||
created_on: 2006-07-19 22:40:26 +02:00
|
||||
project_id: 1
|
||||
title: eCookbook first release !
|
||||
id: 1
|
||||
description: |-
|
||||
eCookbook 1.0 has been released.
|
||||
|
||||
Visit http://ecookbook.somenet.foo/
|
||||
summary: First version was released...
|
||||
author_id: 2
|
||||
comments_count: 1
|
||||
news_002:
|
||||
created_on: 2006-07-19 22:42:58 +02:00
|
||||
project_id: 1
|
||||
title: 100,000 downloads for eCookbook
|
||||
id: 2
|
||||
description: eCookbook 1.0 have downloaded 100,000 times
|
||||
summary: eCookbook 1.0 have downloaded 100,000 times
|
||||
author_id: 2
|
||||
comments_count: 0
|
||||
|
|
|
@ -1,74 +1,74 @@
|
|||
---
|
||||
projects_001:
|
||||
created_on: 2006-07-19 19:13:59 +02:00
|
||||
name: eCookbook
|
||||
updated_on: 2006-07-19 22:53:01 +02:00
|
||||
id: 1
|
||||
description: Recipes management application
|
||||
homepage: http://ecookbook.somenet.foo/
|
||||
is_public: true
|
||||
identifier: ecookbook
|
||||
parent_id:
|
||||
lft: 1
|
||||
rgt: 10
|
||||
projects_002:
|
||||
created_on: 2006-07-19 19:14:19 +02:00
|
||||
name: OnlineStore
|
||||
updated_on: 2006-07-19 19:14:19 +02:00
|
||||
id: 2
|
||||
description: E-commerce web site
|
||||
homepage: ""
|
||||
is_public: false
|
||||
identifier: onlinestore
|
||||
parent_id:
|
||||
lft: 11
|
||||
rgt: 12
|
||||
projects_003:
|
||||
created_on: 2006-07-19 19:15:21 +02:00
|
||||
name: eCookbook Subproject 1
|
||||
updated_on: 2006-07-19 19:18:12 +02:00
|
||||
id: 3
|
||||
description: eCookBook Subproject 1
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: subproject1
|
||||
parent_id: 1
|
||||
lft: 6
|
||||
rgt: 7
|
||||
projects_004:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: eCookbook Subproject 2
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 4
|
||||
description: eCookbook Subproject 2
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: subproject2
|
||||
parent_id: 1
|
||||
lft: 8
|
||||
rgt: 9
|
||||
projects_005:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: Private child of eCookbook
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 5
|
||||
description: This is a private subproject of a public project
|
||||
homepage: ""
|
||||
is_public: false
|
||||
identifier: private-child
|
||||
parent_id: 1
|
||||
lft: 2
|
||||
rgt: 5
|
||||
projects_006:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: Child of private child
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 6
|
||||
description: This is a public subproject of a private project
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: project6
|
||||
parent_id: 5
|
||||
lft: 3
|
||||
rgt: 4
|
||||
---
|
||||
projects_001:
|
||||
created_on: 2006-07-19 19:13:59 +02:00
|
||||
name: eCookbook
|
||||
updated_on: 2006-07-19 22:53:01 +02:00
|
||||
id: 1
|
||||
description: Recipes management application
|
||||
homepage: http://ecookbook.somenet.foo/
|
||||
is_public: true
|
||||
identifier: ecookbook
|
||||
parent_id:
|
||||
lft: 1
|
||||
rgt: 10
|
||||
projects_002:
|
||||
created_on: 2006-07-19 19:14:19 +02:00
|
||||
name: OnlineStore
|
||||
updated_on: 2006-07-19 19:14:19 +02:00
|
||||
id: 2
|
||||
description: E-commerce web site
|
||||
homepage: ""
|
||||
is_public: false
|
||||
identifier: onlinestore
|
||||
parent_id:
|
||||
lft: 11
|
||||
rgt: 12
|
||||
projects_003:
|
||||
created_on: 2006-07-19 19:15:21 +02:00
|
||||
name: eCookbook Subproject 1
|
||||
updated_on: 2006-07-19 19:18:12 +02:00
|
||||
id: 3
|
||||
description: eCookBook Subproject 1
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: subproject1
|
||||
parent_id: 1
|
||||
lft: 6
|
||||
rgt: 7
|
||||
projects_004:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: eCookbook Subproject 2
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 4
|
||||
description: eCookbook Subproject 2
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: subproject2
|
||||
parent_id: 1
|
||||
lft: 8
|
||||
rgt: 9
|
||||
projects_005:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: Private child of eCookbook
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 5
|
||||
description: This is a private subproject of a public project
|
||||
homepage: ""
|
||||
is_public: false
|
||||
identifier: private-child
|
||||
parent_id: 1
|
||||
lft: 2
|
||||
rgt: 5
|
||||
projects_006:
|
||||
created_on: 2006-07-19 19:15:51 +02:00
|
||||
name: Child of private child
|
||||
updated_on: 2006-07-19 19:17:07 +02:00
|
||||
id: 6
|
||||
description: This is a public subproject of a private project
|
||||
homepage: ""
|
||||
is_public: true
|
||||
identifier: project6
|
||||
parent_id: 5
|
||||
lft: 3
|
||||
rgt: 4
|
||||
|
|
@ -1,137 +1,137 @@
|
|||
---
|
||||
queries_001:
|
||||
id: 1
|
||||
project_id: 1
|
||||
is_public: true
|
||||
name: Multiple custom fields query
|
||||
filters: |
|
||||
---
|
||||
cf_1:
|
||||
:values:
|
||||
- MySQL
|
||||
:operator: "="
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
cf_2:
|
||||
:values:
|
||||
- "125"
|
||||
:operator: "="
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
queries_002:
|
||||
id: 2
|
||||
project_id: 1
|
||||
is_public: false
|
||||
name: Private query for cookbook
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 3
|
||||
column_names:
|
||||
queries_003:
|
||||
id: 3
|
||||
project_id:
|
||||
is_public: false
|
||||
name: Private query for all projects
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 3
|
||||
column_names:
|
||||
queries_004:
|
||||
id: 4
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Public query for all projects
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
queries_005:
|
||||
id: 5
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Open issues by priority and tracker
|
||||
filters: |
|
||||
---
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
sort_criteria: |
|
||||
---
|
||||
- - priority
|
||||
- desc
|
||||
- - tracker
|
||||
- asc
|
||||
queries_006:
|
||||
id: 6
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Open issues grouped by tracker
|
||||
filters: |
|
||||
---
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
group_by: tracker
|
||||
sort_criteria: |
|
||||
---
|
||||
- - priority
|
||||
- desc
|
||||
queries_007:
|
||||
id: 7
|
||||
project_id: 2
|
||||
is_public: true
|
||||
name: Public query for project 2
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
queries_008:
|
||||
id: 8
|
||||
project_id: 2
|
||||
is_public: false
|
||||
name: Private query for project 2
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
---
|
||||
queries_001:
|
||||
id: 1
|
||||
project_id: 1
|
||||
is_public: true
|
||||
name: Multiple custom fields query
|
||||
filters: |
|
||||
---
|
||||
cf_1:
|
||||
:values:
|
||||
- MySQL
|
||||
:operator: "="
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
cf_2:
|
||||
:values:
|
||||
- "125"
|
||||
:operator: "="
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
queries_002:
|
||||
id: 2
|
||||
project_id: 1
|
||||
is_public: false
|
||||
name: Private query for cookbook
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 3
|
||||
column_names:
|
||||
queries_003:
|
||||
id: 3
|
||||
project_id:
|
||||
is_public: false
|
||||
name: Private query for all projects
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 3
|
||||
column_names:
|
||||
queries_004:
|
||||
id: 4
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Public query for all projects
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
queries_005:
|
||||
id: 5
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Open issues by priority and tracker
|
||||
filters: |
|
||||
---
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
sort_criteria: |
|
||||
---
|
||||
- - priority
|
||||
- desc
|
||||
- - tracker
|
||||
- asc
|
||||
queries_006:
|
||||
id: 6
|
||||
project_id:
|
||||
is_public: true
|
||||
name: Open issues grouped by tracker
|
||||
filters: |
|
||||
---
|
||||
status_id:
|
||||
:values:
|
||||
- "1"
|
||||
:operator: o
|
||||
|
||||
user_id: 1
|
||||
column_names:
|
||||
group_by: tracker
|
||||
sort_criteria: |
|
||||
---
|
||||
- - priority
|
||||
- desc
|
||||
queries_007:
|
||||
id: 7
|
||||
project_id: 2
|
||||
is_public: true
|
||||
name: Public query for project 2
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
queries_008:
|
||||
id: 8
|
||||
project_id: 2
|
||||
is_public: false
|
||||
name: Private query for project 2
|
||||
filters: |
|
||||
---
|
||||
tracker_id:
|
||||
:values:
|
||||
- "3"
|
||||
:operator: "="
|
||||
|
||||
user_id: 2
|
||||
column_names:
|
||||
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
---
|
||||
repositories_001:
|
||||
project_id: 1
|
||||
url: file:///<%= RAILS_ROOT.gsub(%r{config\/\.\.}, '') %>/tmp/test/subversion_repository
|
||||
id: 10
|
||||
root_url: file:///<%= RAILS_ROOT.gsub(%r{config\/\.\.}, '') %>/tmp/test/subversion_repository
|
||||
password: ""
|
||||
login: ""
|
||||
type: Subversion
|
||||
repositories_002:
|
||||
project_id: 2
|
||||
url: svn://localhost/test
|
||||
id: 11
|
||||
root_url: svn://localhost
|
||||
password: ""
|
||||
login: ""
|
||||
type: Subversion
|
||||
---
|
||||
repositories_001:
|
||||
project_id: 1
|
||||
url: file:///<%= RAILS_ROOT.gsub(%r{config\/\.\.}, '') %>/tmp/test/subversion_repository
|
||||
id: 10
|
||||
root_url: file:///<%= RAILS_ROOT.gsub(%r{config\/\.\.}, '') %>/tmp/test/subversion_repository
|
||||
password: ""
|
||||
login: ""
|
||||
type: Subversion
|
||||
repositories_002:
|
||||
project_id: 2
|
||||
url: svn://localhost/test
|
||||
id: 11
|
||||
root_url: svn://localhost
|
||||
password: ""
|
||||
login: ""
|
||||
type: Subversion
|
||||
|
|
|
@ -1,177 +1,177 @@
|
|||
---
|
||||
roles_001:
|
||||
name: Manager
|
||||
id: 1
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :add_project
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :delete_issues
|
||||
- :view_issue_watchers
|
||||
- :add_issue_watchers
|
||||
- :manage_public_queries
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :edit_time_entries
|
||||
- :delete_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :delete_wiki_pages_attachments
|
||||
- :protect_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :rename_wiki_pages
|
||||
- :add_messages
|
||||
- :edit_messages
|
||||
- :delete_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :manage_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 1
|
||||
roles_002:
|
||||
name: Developer
|
||||
id: 2
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :delete_issues
|
||||
- :view_issue_watchers
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :edit_own_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :protect_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :add_messages
|
||||
- :edit_own_messages
|
||||
- :delete_own_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 2
|
||||
roles_003:
|
||||
name: Reporter
|
||||
id: 3
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :view_issue_watchers
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :add_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 3
|
||||
roles_004:
|
||||
name: Non member
|
||||
id: 4
|
||||
builtin: 1
|
||||
permissions: |
|
||||
---
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :add_messages
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 4
|
||||
roles_005:
|
||||
name: Anonymous
|
||||
id: 5
|
||||
builtin: 2
|
||||
permissions: |
|
||||
---
|
||||
- :add_issue_notes
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :view_time_entries
|
||||
- :view_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :view_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 5
|
||||
---
|
||||
roles_001:
|
||||
name: Manager
|
||||
id: 1
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :add_project
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :delete_issues
|
||||
- :view_issue_watchers
|
||||
- :add_issue_watchers
|
||||
- :manage_public_queries
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :edit_time_entries
|
||||
- :delete_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :delete_wiki_pages_attachments
|
||||
- :protect_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :rename_wiki_pages
|
||||
- :add_messages
|
||||
- :edit_messages
|
||||
- :delete_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :manage_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 1
|
||||
roles_002:
|
||||
name: Developer
|
||||
id: 2
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :delete_issues
|
||||
- :view_issue_watchers
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :edit_own_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :protect_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :add_messages
|
||||
- :edit_own_messages
|
||||
- :delete_own_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 2
|
||||
roles_003:
|
||||
name: Reporter
|
||||
id: 3
|
||||
builtin: 0
|
||||
permissions: |
|
||||
---
|
||||
- :edit_project
|
||||
- :manage_members
|
||||
- :manage_versions
|
||||
- :manage_categories
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :view_issue_watchers
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :manage_news
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :delete_wiki_pages
|
||||
- :add_messages
|
||||
- :manage_boards
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 3
|
||||
roles_004:
|
||||
name: Non member
|
||||
id: 4
|
||||
builtin: 1
|
||||
permissions: |
|
||||
---
|
||||
- :add_issues
|
||||
- :edit_issues
|
||||
- :manage_issue_relations
|
||||
- :add_issue_notes
|
||||
- :move_issues
|
||||
- :save_queries
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :log_time
|
||||
- :view_time_entries
|
||||
- :comment_news
|
||||
- :view_documents
|
||||
- :manage_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :edit_wiki_pages
|
||||
- :add_messages
|
||||
- :view_files
|
||||
- :manage_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 4
|
||||
roles_005:
|
||||
name: Anonymous
|
||||
id: 5
|
||||
builtin: 2
|
||||
permissions: |
|
||||
---
|
||||
- :add_issue_notes
|
||||
- :view_gantt
|
||||
- :view_calendar
|
||||
- :view_time_entries
|
||||
- :view_documents
|
||||
- :view_wiki_pages
|
||||
- :view_wiki_edits
|
||||
- :view_files
|
||||
- :browse_repository
|
||||
- :view_changesets
|
||||
|
||||
position: 5
|
||||
|
|
@ -1,58 +1,58 @@
|
|||
---
|
||||
time_entries_001:
|
||||
created_on: 2007-03-23 12:54:18 +01:00
|
||||
tweek: 12
|
||||
tmonth: 3
|
||||
project_id: 1
|
||||
comments: My hours
|
||||
updated_on: 2007-03-23 12:54:18 +01:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-03-23
|
||||
issue_id: 1
|
||||
id: 1
|
||||
hours: 4.25
|
||||
user_id: 2
|
||||
tyear: 2007
|
||||
time_entries_002:
|
||||
created_on: 2007-03-23 14:11:04 +01:00
|
||||
tweek: 11
|
||||
tmonth: 3
|
||||
project_id: 1
|
||||
comments: ""
|
||||
updated_on: 2007-03-23 14:11:04 +01:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-03-12
|
||||
issue_id: 1
|
||||
id: 2
|
||||
hours: 150.0
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
time_entries_003:
|
||||
created_on: 2007-04-21 12:20:48 +02:00
|
||||
tweek: 16
|
||||
tmonth: 4
|
||||
project_id: 1
|
||||
comments: ""
|
||||
updated_on: 2007-04-21 12:20:48 +02:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-04-21
|
||||
issue_id: 3
|
||||
id: 3
|
||||
hours: 1.0
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
time_entries_004:
|
||||
created_on: 2007-04-22 12:20:48 +02:00
|
||||
tweek: 16
|
||||
tmonth: 4
|
||||
project_id: 3
|
||||
comments: Time spent on a subproject
|
||||
updated_on: 2007-04-22 12:20:48 +02:00
|
||||
activity_id: 10
|
||||
spent_on: 2007-04-22
|
||||
issue_id:
|
||||
id: 4
|
||||
hours: 7.65
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
---
|
||||
time_entries_001:
|
||||
created_on: 2007-03-23 12:54:18 +01:00
|
||||
tweek: 12
|
||||
tmonth: 3
|
||||
project_id: 1
|
||||
comments: My hours
|
||||
updated_on: 2007-03-23 12:54:18 +01:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-03-23
|
||||
issue_id: 1
|
||||
id: 1
|
||||
hours: 4.25
|
||||
user_id: 2
|
||||
tyear: 2007
|
||||
time_entries_002:
|
||||
created_on: 2007-03-23 14:11:04 +01:00
|
||||
tweek: 11
|
||||
tmonth: 3
|
||||
project_id: 1
|
||||
comments: ""
|
||||
updated_on: 2007-03-23 14:11:04 +01:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-03-12
|
||||
issue_id: 1
|
||||
id: 2
|
||||
hours: 150.0
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
time_entries_003:
|
||||
created_on: 2007-04-21 12:20:48 +02:00
|
||||
tweek: 16
|
||||
tmonth: 4
|
||||
project_id: 1
|
||||
comments: ""
|
||||
updated_on: 2007-04-21 12:20:48 +02:00
|
||||
activity_id: 9
|
||||
spent_on: 2007-04-21
|
||||
issue_id: 3
|
||||
id: 3
|
||||
hours: 1.0
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
time_entries_004:
|
||||
created_on: 2007-04-22 12:20:48 +02:00
|
||||
tweek: 16
|
||||
tmonth: 4
|
||||
project_id: 3
|
||||
comments: Time spent on a subproject
|
||||
updated_on: 2007-04-22 12:20:48 +02:00
|
||||
activity_id: 10
|
||||
spent_on: 2007-04-22
|
||||
issue_id:
|
||||
id: 4
|
||||
hours: 7.65
|
||||
user_id: 1
|
||||
tyear: 2007
|
||||
|
|
@ -1,13 +1,13 @@
|
|||
---
|
||||
tokens_001:
|
||||
created_on: 2007-01-21 00:39:12 +01:00
|
||||
action: register
|
||||
id: 1
|
||||
value: DwMJ2yIxBNeAk26znMYzYmz5dAiIina0GFrPnGTM
|
||||
user_id: 1
|
||||
tokens_002:
|
||||
created_on: 2007-01-21 00:39:52 +01:00
|
||||
action: recovery
|
||||
id: 2
|
||||
value: sahYSIaoYrsZUef86sTHrLISdznW6ApF36h5WSnm
|
||||
user_id: 2
|
||||
---
|
||||
tokens_001:
|
||||
created_on: 2007-01-21 00:39:12 +01:00
|
||||
action: register
|
||||
id: 1
|
||||
value: DwMJ2yIxBNeAk26znMYzYmz5dAiIina0GFrPnGTM
|
||||
user_id: 1
|
||||
tokens_002:
|
||||
created_on: 2007-01-21 00:39:52 +01:00
|
||||
action: recovery
|
||||
id: 2
|
||||
value: sahYSIaoYrsZUef86sTHrLISdznW6ApF36h5WSnm
|
||||
user_id: 2
|
||||
|
|
|
@ -1,16 +1,16 @@
|
|||
---
|
||||
trackers_001:
|
||||
name: Bug
|
||||
id: 1
|
||||
is_in_chlog: true
|
||||
position: 1
|
||||
trackers_002:
|
||||
name: Feature request
|
||||
id: 2
|
||||
is_in_chlog: true
|
||||
position: 2
|
||||
trackers_003:
|
||||
name: Support request
|
||||
id: 3
|
||||
is_in_chlog: false
|
||||
position: 3
|
||||
---
|
||||
trackers_001:
|
||||
name: Bug
|
||||
id: 1
|
||||
is_in_chlog: true
|
||||
position: 1
|
||||
trackers_002:
|
||||
name: Feature request
|
||||
id: 2
|
||||
is_in_chlog: true
|
||||
position: 2
|
||||
trackers_003:
|
||||
name: Support request
|
||||
id: 3
|
||||
is_in_chlog: false
|
||||
position: 3
|
||||
|
|
|
@ -1,156 +1,156 @@
|
|||
---
|
||||
users_004:
|
||||
created_on: 2006-07-19 19:34:07 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 4e4aeb7baaf0706bd670263fef42dad15763b608
|
||||
updated_on: 2006-07-19 19:34:07 +02:00
|
||||
admin: false
|
||||
mail: rhill@somenet.foo
|
||||
lastname: Hill
|
||||
firstname: Robert
|
||||
id: 4
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: rhill
|
||||
type: User
|
||||
users_001:
|
||||
created_on: 2006-07-19 19:12:21 +02:00
|
||||
status: 1
|
||||
last_login_on: 2006-07-19 22:57:52 +02:00
|
||||
language: en
|
||||
hashed_password: d033e22ae348aeb5660fc2140aec35850c4da997
|
||||
updated_on: 2006-07-19 22:57:52 +02:00
|
||||
admin: true
|
||||
mail: admin@somenet.foo
|
||||
lastname: Admin
|
||||
firstname: redMine
|
||||
id: 1
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: admin
|
||||
type: User
|
||||
users_002:
|
||||
created_on: 2006-07-19 19:32:09 +02:00
|
||||
status: 1
|
||||
last_login_on: 2006-07-19 22:42:15 +02:00
|
||||
language: en
|
||||
hashed_password: a9a653d4151fa2c081ba1ffc2c2726f3b80b7d7d
|
||||
updated_on: 2006-07-19 22:42:15 +02:00
|
||||
admin: false
|
||||
mail: jsmith@somenet.foo
|
||||
lastname: Smith
|
||||
firstname: John
|
||||
id: 2
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: jsmith
|
||||
type: User
|
||||
users_003:
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 7feb7657aa7a7bf5aef3414a5084875f27192415
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: dlopper@somenet.foo
|
||||
lastname: Lopper
|
||||
firstname: Dave
|
||||
id: 3
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: dlopper
|
||||
type: User
|
||||
users_005:
|
||||
id: 5
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
# Locked
|
||||
status: 3
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 7feb7657aa7a7bf5aef3414a5084875f27192415
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: dlopper2@somenet.foo
|
||||
lastname: Lopper2
|
||||
firstname: Dave2
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: dlopper2
|
||||
type: User
|
||||
users_006:
|
||||
id: 6
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: ''
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: ''
|
||||
lastname: Anonymous
|
||||
firstname: ''
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: ''
|
||||
type: AnonymousUser
|
||||
users_007:
|
||||
id: 7
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: ''
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: someone@foo.bar
|
||||
lastname: One
|
||||
firstname: Some
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: someone
|
||||
type: User
|
||||
users_008:
|
||||
id: 8
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: 'it'
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: miscuser8@foo.bar
|
||||
lastname: Misc
|
||||
firstname: User
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: miscuser8
|
||||
type: User
|
||||
users_009:
|
||||
id: 9
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: 'it'
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: miscuser9@foo.bar
|
||||
lastname: Misc
|
||||
firstname: User
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: miscuser9
|
||||
type: User
|
||||
groups_010:
|
||||
id: 10
|
||||
lastname: A Team
|
||||
type: Group
|
||||
groups_011:
|
||||
id: 11
|
||||
lastname: B Team
|
||||
type: Group
|
||||
|
||||
---
|
||||
users_004:
|
||||
created_on: 2006-07-19 19:34:07 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 4e4aeb7baaf0706bd670263fef42dad15763b608
|
||||
updated_on: 2006-07-19 19:34:07 +02:00
|
||||
admin: false
|
||||
mail: rhill@somenet.foo
|
||||
lastname: Hill
|
||||
firstname: Robert
|
||||
id: 4
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: rhill
|
||||
type: User
|
||||
users_001:
|
||||
created_on: 2006-07-19 19:12:21 +02:00
|
||||
status: 1
|
||||
last_login_on: 2006-07-19 22:57:52 +02:00
|
||||
language: en
|
||||
hashed_password: d033e22ae348aeb5660fc2140aec35850c4da997
|
||||
updated_on: 2006-07-19 22:57:52 +02:00
|
||||
admin: true
|
||||
mail: admin@somenet.foo
|
||||
lastname: Admin
|
||||
firstname: redMine
|
||||
id: 1
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: admin
|
||||
type: User
|
||||
users_002:
|
||||
created_on: 2006-07-19 19:32:09 +02:00
|
||||
status: 1
|
||||
last_login_on: 2006-07-19 22:42:15 +02:00
|
||||
language: en
|
||||
hashed_password: a9a653d4151fa2c081ba1ffc2c2726f3b80b7d7d
|
||||
updated_on: 2006-07-19 22:42:15 +02:00
|
||||
admin: false
|
||||
mail: jsmith@somenet.foo
|
||||
lastname: Smith
|
||||
firstname: John
|
||||
id: 2
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: jsmith
|
||||
type: User
|
||||
users_003:
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 7feb7657aa7a7bf5aef3414a5084875f27192415
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: dlopper@somenet.foo
|
||||
lastname: Lopper
|
||||
firstname: Dave
|
||||
id: 3
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: dlopper
|
||||
type: User
|
||||
users_005:
|
||||
id: 5
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
# Locked
|
||||
status: 3
|
||||
last_login_on:
|
||||
language: en
|
||||
hashed_password: 7feb7657aa7a7bf5aef3414a5084875f27192415
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: dlopper2@somenet.foo
|
||||
lastname: Lopper2
|
||||
firstname: Dave2
|
||||
auth_source_id:
|
||||
mail_notification: true
|
||||
login: dlopper2
|
||||
type: User
|
||||
users_006:
|
||||
id: 6
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: ''
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: ''
|
||||
lastname: Anonymous
|
||||
firstname: ''
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: ''
|
||||
type: AnonymousUser
|
||||
users_007:
|
||||
id: 7
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: ''
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: someone@foo.bar
|
||||
lastname: One
|
||||
firstname: Some
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: someone
|
||||
type: User
|
||||
users_008:
|
||||
id: 8
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: 'it'
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: miscuser8@foo.bar
|
||||
lastname: Misc
|
||||
firstname: User
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: miscuser8
|
||||
type: User
|
||||
users_009:
|
||||
id: 9
|
||||
created_on: 2006-07-19 19:33:19 +02:00
|
||||
status: 1
|
||||
last_login_on:
|
||||
language: 'it'
|
||||
hashed_password: 1
|
||||
updated_on: 2006-07-19 19:33:19 +02:00
|
||||
admin: false
|
||||
mail: miscuser9@foo.bar
|
||||
lastname: Misc
|
||||
firstname: User
|
||||
auth_source_id:
|
||||
mail_notification: false
|
||||
login: miscuser9
|
||||
type: User
|
||||
groups_010:
|
||||
id: 10
|
||||
lastname: A Team
|
||||
type: Group
|
||||
groups_011:
|
||||
id: 11
|
||||
lastname: B Team
|
||||
type: Group
|
||||
|
||||
|
|
@ -1,26 +1,26 @@
|
|||
---
|
||||
versions_001:
|
||||
created_on: 2006-07-19 21:00:07 +02:00
|
||||
name: "0.1"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:07 +02:00
|
||||
id: 1
|
||||
description: Beta
|
||||
effective_date: 2006-07-01
|
||||
versions_002:
|
||||
created_on: 2006-07-19 21:00:33 +02:00
|
||||
name: "1.0"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:33 +02:00
|
||||
id: 2
|
||||
description: Stable release
|
||||
effective_date: <%= 20.day.from_now.to_date.to_s(:db) %>
|
||||
versions_003:
|
||||
created_on: 2006-07-19 21:00:33 +02:00
|
||||
name: "2.0"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:33 +02:00
|
||||
id: 3
|
||||
description: Future version
|
||||
effective_date:
|
||||
---
|
||||
versions_001:
|
||||
created_on: 2006-07-19 21:00:07 +02:00
|
||||
name: "0.1"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:07 +02:00
|
||||
id: 1
|
||||
description: Beta
|
||||
effective_date: 2006-07-01
|
||||
versions_002:
|
||||
created_on: 2006-07-19 21:00:33 +02:00
|
||||
name: "1.0"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:33 +02:00
|
||||
id: 2
|
||||
description: Stable release
|
||||
effective_date: <%= 20.day.from_now.to_date.to_s(:db) %>
|
||||
versions_003:
|
||||
created_on: 2006-07-19 21:00:33 +02:00
|
||||
name: "2.0"
|
||||
project_id: 1
|
||||
updated_on: 2006-07-19 21:00:33 +02:00
|
||||
id: 3
|
||||
description: Future version
|
||||
effective_date:
|
||||
|
|
@ -1,52 +1,56 @@
|
|||
---
|
||||
wiki_content_versions_001:
|
||||
updated_on: 2007-03-07 00:08:07 +01:00
|
||||
page_id: 1
|
||||
id: 1
|
||||
version: 1
|
||||
author_id: 2
|
||||
comments: Page creation
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
|
||||
Some [[documentation]] here...
|
||||
wiki_content_versions_002:
|
||||
updated_on: 2007-03-07 00:08:34 +01:00
|
||||
page_id: 1
|
||||
id: 2
|
||||
version: 2
|
||||
author_id: 1
|
||||
comments: Small update
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
|
||||
Some updated [[documentation]] here...
|
||||
wiki_content_versions_003:
|
||||
updated_on: 2007-03-07 00:10:51 +01:00
|
||||
page_id: 1
|
||||
id: 3
|
||||
version: 3
|
||||
author_id: 1
|
||||
comments: ""
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
Some updated [[documentation]] here...
|
||||
wiki_content_versions_004:
|
||||
data: |-
|
||||
h1. Another page
|
||||
|
||||
This is a link to a ticket: #2
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 2
|
||||
wiki_content_id: 2
|
||||
id: 4
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
|
||||
---
|
||||
wiki_content_versions_001:
|
||||
updated_on: 2007-03-07 00:08:07 +01:00
|
||||
page_id: 1
|
||||
id: 1
|
||||
version: 1
|
||||
author_id: 2
|
||||
comments: Page creation
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
|
||||
|
||||
|
||||
Some [[documentation]] here...
|
||||
wiki_content_versions_002:
|
||||
updated_on: 2007-03-07 00:08:34 +01:00
|
||||
page_id: 1
|
||||
id: 2
|
||||
version: 2
|
||||
author_id: 1
|
||||
comments: Small update
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
|
||||
|
||||
|
||||
Some updated [[documentation]] here...
|
||||
wiki_content_versions_003:
|
||||
updated_on: 2007-03-07 00:10:51 +01:00
|
||||
page_id: 1
|
||||
id: 3
|
||||
version: 3
|
||||
author_id: 1
|
||||
comments: ""
|
||||
wiki_content_id: 1
|
||||
compression: ""
|
||||
data: |-
|
||||
h1. CookBook documentation
|
||||
Some updated [[documentation]] here...
|
||||
wiki_content_versions_004:
|
||||
data: |-
|
||||
h1. Another page
|
||||
|
||||
This is a link to a ticket: #2
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 2
|
||||
wiki_content_id: 2
|
||||
id: 4
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
|
||||
|
|
|
@ -1,72 +1,74 @@
|
|||
---
|
||||
wiki_contents_001:
|
||||
text: |-
|
||||
h1. CookBook documentation
|
||||
{{child_pages}}
|
||||
Some updated [[documentation]] here with gzipped history
|
||||
updated_on: 2007-03-07 00:10:51 +01:00
|
||||
page_id: 1
|
||||
id: 1
|
||||
version: 3
|
||||
author_id: 1
|
||||
comments: Gzip compression activated
|
||||
wiki_contents_002:
|
||||
text: |-
|
||||
h1. Another page
|
||||
|
||||
This is a link to a ticket: #2
|
||||
And this is an included page:
|
||||
{{include(Page with an inline image)}}
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 2
|
||||
id: 2
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_003:
|
||||
text: |-
|
||||
h1. Start page
|
||||
|
||||
E-commerce web site start page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 3
|
||||
id: 3
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_004:
|
||||
text: |-
|
||||
h1. Page with an inline image
|
||||
|
||||
This is an inline image:
|
||||
|
||||
!logo.gif!
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 4
|
||||
id: 4
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_005:
|
||||
text: |-
|
||||
h1. Child page 1
|
||||
|
||||
This is a child page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 5
|
||||
id: 5
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_006:
|
||||
text: |-
|
||||
h1. Child page 2
|
||||
|
||||
This is a child page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 6
|
||||
id: 6
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
---
|
||||
wiki_contents_001:
|
||||
text: |-
|
||||
h1. CookBook documentation
|
||||
|
||||
{{child_pages}}
|
||||
|
||||
Some updated [[documentation]] here with gzipped history
|
||||
updated_on: 2007-03-07 00:10:51 +01:00
|
||||
page_id: 1
|
||||
id: 1
|
||||
version: 3
|
||||
author_id: 1
|
||||
comments: Gzip compression activated
|
||||
wiki_contents_002:
|
||||
text: |-
|
||||
h1. Another page
|
||||
|
||||
This is a link to a ticket: #2
|
||||
And this is an included page:
|
||||
{{include(Page with an inline image)}}
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 2
|
||||
id: 2
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_003:
|
||||
text: |-
|
||||
h1. Start page
|
||||
|
||||
E-commerce web site start page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 3
|
||||
id: 3
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_004:
|
||||
text: |-
|
||||
h1. Page with an inline image
|
||||
|
||||
This is an inline image:
|
||||
|
||||
!logo.gif!
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 4
|
||||
id: 4
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_005:
|
||||
text: |-
|
||||
h1. Child page 1
|
||||
|
||||
This is a child page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 5
|
||||
id: 5
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
wiki_contents_006:
|
||||
text: |-
|
||||
h1. Child page 2
|
||||
|
||||
This is a child page
|
||||
updated_on: 2007-03-08 00:18:07 +01:00
|
||||
page_id: 6
|
||||
id: 6
|
||||
version: 1
|
||||
author_id: 1
|
||||
comments:
|
||||
|
|
@ -1,44 +1,44 @@
|
|||
---
|
||||
wiki_pages_001:
|
||||
created_on: 2007-03-07 00:08:07 +01:00
|
||||
title: CookBook_documentation
|
||||
id: 1
|
||||
wiki_id: 1
|
||||
protected: true
|
||||
parent_id:
|
||||
wiki_pages_002:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Another_page
|
||||
id: 2
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id:
|
||||
wiki_pages_003:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Start_page
|
||||
id: 3
|
||||
wiki_id: 2
|
||||
protected: false
|
||||
parent_id:
|
||||
wiki_pages_004:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Page_with_an_inline_image
|
||||
id: 4
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 1
|
||||
wiki_pages_005:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Child_1
|
||||
id: 5
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 2
|
||||
wiki_pages_006:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Child_2
|
||||
id: 6
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 2
|
||||
---
|
||||
wiki_pages_001:
|
||||
created_on: 2007-03-07 00:08:07 +01:00
|
||||
title: CookBook_documentation
|
||||
id: 1
|
||||
wiki_id: 1
|
||||
protected: true
|
||||
parent_id:
|
||||
wiki_pages_002:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Another_page
|
||||
id: 2
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id:
|
||||
wiki_pages_003:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Start_page
|
||||
id: 3
|
||||
wiki_id: 2
|
||||
protected: false
|
||||
parent_id:
|
||||
wiki_pages_004:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Page_with_an_inline_image
|
||||
id: 4
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 1
|
||||
wiki_pages_005:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Child_1
|
||||
id: 5
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 2
|
||||
wiki_pages_006:
|
||||
created_on: 2007-03-08 00:18:07 +01:00
|
||||
title: Child_2
|
||||
id: 6
|
||||
wiki_id: 1
|
||||
protected: false
|
||||
parent_id: 2
|
||||
|
|
@ -1,12 +1,12 @@
|
|||
---
|
||||
wikis_001:
|
||||
status: 1
|
||||
start_page: CookBook documentation
|
||||
project_id: 1
|
||||
id: 1
|
||||
wikis_002:
|
||||
status: 1
|
||||
start_page: Start page
|
||||
project_id: 2
|
||||
id: 2
|
||||
---
|
||||
wikis_001:
|
||||
status: 1
|
||||
start_page: CookBook documentation
|
||||
project_id: 1
|
||||
id: 1
|
||||
wikis_002:
|
||||
status: 1
|
||||
start_page: Start page
|
||||
project_id: 2
|
||||
id: 2
|
||||
|
File diff suppressed because it is too large
Load Diff
|
@ -1,61 +1,61 @@
|
|||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
require 'custom_fields_controller'
|
||||
|
||||
# Re-raise errors caught by the controller.
|
||||
class CustomFieldsController; def rescue_action(e) raise e end; end
|
||||
|
||||
class CustomFieldsControllerTest < ActionController::TestCase
|
||||
fixtures :custom_fields, :trackers, :users
|
||||
|
||||
def setup
|
||||
@controller = CustomFieldsController.new
|
||||
@request = ActionController::TestRequest.new
|
||||
@response = ActionController::TestResponse.new
|
||||
@request.session[:user_id] = 1
|
||||
end
|
||||
|
||||
def test_post_new_list_custom_field
|
||||
assert_difference 'CustomField.count' do
|
||||
post :new, :type => "IssueCustomField",
|
||||
:custom_field => {:name => "test_post_new_list",
|
||||
:default_value => "",
|
||||
:min_length => "0",
|
||||
:searchable => "0",
|
||||
:regexp => "",
|
||||
:is_for_all => "1",
|
||||
:possible_values => "0.1\n0.2\n",
|
||||
:max_length => "0",
|
||||
:is_filter => "0",
|
||||
:is_required =>"0",
|
||||
:field_format => "list",
|
||||
:tracker_ids => ["1", ""]}
|
||||
end
|
||||
assert_redirected_to '/custom_fields?tab=IssueCustomField'
|
||||
field = IssueCustomField.find_by_name('test_post_new_list')
|
||||
assert_not_nil field
|
||||
assert_equal ["0.1", "0.2"], field.possible_values
|
||||
assert_equal 1, field.trackers.size
|
||||
end
|
||||
|
||||
def test_invalid_custom_field_class_should_redirect_to_list
|
||||
get :new, :type => 'UnknownCustomField'
|
||||
assert_redirected_to '/custom_fields'
|
||||
end
|
||||
end
|
||||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
require 'custom_fields_controller'
|
||||
|
||||
# Re-raise errors caught by the controller.
|
||||
class CustomFieldsController; def rescue_action(e) raise e end; end
|
||||
|
||||
class CustomFieldsControllerTest < ActionController::TestCase
|
||||
fixtures :custom_fields, :trackers, :users
|
||||
|
||||
def setup
|
||||
@controller = CustomFieldsController.new
|
||||
@request = ActionController::TestRequest.new
|
||||
@response = ActionController::TestResponse.new
|
||||
@request.session[:user_id] = 1
|
||||
end
|
||||
|
||||
def test_post_new_list_custom_field
|
||||
assert_difference 'CustomField.count' do
|
||||
post :new, :type => "IssueCustomField",
|
||||
:custom_field => {:name => "test_post_new_list",
|
||||
:default_value => "",
|
||||
:min_length => "0",
|
||||
:searchable => "0",
|
||||
:regexp => "",
|
||||
:is_for_all => "1",
|
||||
:possible_values => "0.1\n0.2\n",
|
||||
:max_length => "0",
|
||||
:is_filter => "0",
|
||||
:is_required =>"0",
|
||||
:field_format => "list",
|
||||
:tracker_ids => ["1", ""]}
|
||||
end
|
||||
assert_redirected_to '/custom_fields?tab=IssueCustomField'
|
||||
field = IssueCustomField.find_by_name('test_post_new_list')
|
||||
assert_not_nil field
|
||||
assert_equal ["0.1", "0.2"], field.possible_values
|
||||
assert_equal 1, field.trackers.size
|
||||
end
|
||||
|
||||
def test_invalid_custom_field_class_should_redirect_to_list
|
||||
get :new, :type => 'UnknownCustomField'
|
||||
assert_redirected_to '/custom_fields'
|
||||
end
|
||||
end
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,85 +1,85 @@
|
|||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../../test_helper'
|
||||
|
||||
class SortHelperTest < HelperTestCase
|
||||
include SortHelper
|
||||
|
||||
def setup
|
||||
@session = nil
|
||||
@sort_param = nil
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_array
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update(['attr1', 'attr2'])
|
||||
|
||||
assert_equal 'attr1 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_hash
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_multiple_columns
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => ['table1.attr1', 'table1.attr2'], 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC, table1.attr2 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_params_sort
|
||||
@sort_param = 'attr1,attr2:desc'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1, table2.attr2 DESC', sort_clause
|
||||
assert_equal 'attr1,attr2:desc', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
def test_invalid_params_sort
|
||||
@sort_param = 'invalid_key'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC', sort_clause
|
||||
assert_equal 'attr1:desc', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
def test_invalid_order_params_sort
|
||||
@sort_param = 'attr1:foo:bar,attr2'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1, table2.attr2', sort_clause
|
||||
assert_equal 'attr1,attr2', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def controller_name; 'foo'; end
|
||||
def action_name; 'bar'; end
|
||||
def params; {:sort => @sort_param}; end
|
||||
def session; @session ||= {}; end
|
||||
end
|
||||
# Redmine - project management software
|
||||
# Copyright (C) 2006-2009 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../../test_helper'
|
||||
|
||||
class SortHelperTest < HelperTestCase
|
||||
include SortHelper
|
||||
|
||||
def setup
|
||||
@session = nil
|
||||
@sort_param = nil
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_array
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update(['attr1', 'attr2'])
|
||||
|
||||
assert_equal 'attr1 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_hash
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_default_sort_clause_with_multiple_columns
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => ['table1.attr1', 'table1.attr2'], 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC, table1.attr2 DESC', sort_clause
|
||||
end
|
||||
|
||||
def test_params_sort
|
||||
@sort_param = 'attr1,attr2:desc'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1, table2.attr2 DESC', sort_clause
|
||||
assert_equal 'attr1,attr2:desc', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
def test_invalid_params_sort
|
||||
@sort_param = 'invalid_key'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1 DESC', sort_clause
|
||||
assert_equal 'attr1:desc', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
def test_invalid_order_params_sort
|
||||
@sort_param = 'attr1:foo:bar,attr2'
|
||||
|
||||
sort_init 'attr1', 'desc'
|
||||
sort_update({'attr1' => 'table1.attr1', 'attr2' => 'table2.attr2'})
|
||||
|
||||
assert_equal 'table1.attr1, table2.attr2', sort_clause
|
||||
assert_equal 'attr1,attr2', @session['foo_bar_sort']
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def controller_name; 'foo'; end
|
||||
def action_name; 'bar'; end
|
||||
def params; {:sort => @sort_param}; end
|
||||
def session; @session ||= {}; end
|
||||
end
|
||||
|
|
|
@ -24,21 +24,21 @@ class MemberTest < ActiveSupport::TestCase
|
|||
@jsmith = Member.find(1)
|
||||
end
|
||||
|
||||
def test_create
|
||||
member = Member.new(:project_id => 1, :user_id => 4, :role_ids => [1, 2])
|
||||
def test_create
|
||||
member = Member.new(:project_id => 1, :user_id => 4, :role_ids => [1, 2])
|
||||
assert member.save
|
||||
member.reload
|
||||
|
||||
assert_equal 2, member.roles.size
|
||||
assert_equal Role.find(1), member.roles.sort.first
|
||||
end
|
||||
assert_equal Role.find(1), member.roles.sort.first
|
||||
end
|
||||
|
||||
def test_update
|
||||
assert_equal "eCookbook", @jsmith.project.name
|
||||
assert_equal "Manager", @jsmith.roles.first.name
|
||||
assert_equal "jsmith", @jsmith.user.login
|
||||
|
||||
@jsmith.mail_notification = !@jsmith.mail_notification
|
||||
assert_equal "eCookbook", @jsmith.project.name
|
||||
assert_equal "Manager", @jsmith.roles.first.name
|
||||
assert_equal "jsmith", @jsmith.user.login
|
||||
|
||||
@jsmith.mail_notification = !@jsmith.mail_notification
|
||||
assert @jsmith.save
|
||||
end
|
||||
|
||||
|
@ -48,24 +48,24 @@ class MemberTest < ActiveSupport::TestCase
|
|||
assert @jsmith.save
|
||||
assert_equal 2, @jsmith.reload.roles.size
|
||||
end
|
||||
|
||||
def test_validate
|
||||
member = Member.new(:project_id => 1, :user_id => 2, :role_ids => [2])
|
||||
# same use can't have more than one membership for a project
|
||||
|
||||
def test_validate
|
||||
member = Member.new(:project_id => 1, :user_id => 2, :role_ids => [2])
|
||||
# same use can't have more than one membership for a project
|
||||
assert !member.save
|
||||
|
||||
member = Member.new(:project_id => 1, :user_id => 2, :role_ids => [])
|
||||
# must have one role at least
|
||||
assert !member.save
|
||||
end
|
||||
|
||||
assert !member.save
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
assert_difference 'Member.count', -1 do
|
||||
assert_difference 'MemberRole.count', -1 do
|
||||
assert_difference 'MemberRole.count', -1 do
|
||||
@jsmith.destroy
|
||||
end
|
||||
end
|
||||
|
||||
assert_raise(ActiveRecord::RecordNotFound) { Member.find(@jsmith.id) }
|
||||
|
||||
assert_raise(ActiveRecord::RecordNotFound) { Member.find(@jsmith.id) }
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,355 +1,355 @@
|
|||
# redMine - project management software
|
||||
# Copyright (C) 2006-2007 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
|
||||
class ProjectTest < ActiveSupport::TestCase
|
||||
fixtures :projects, :enabled_modules,
|
||||
:issues, :issue_statuses, :journals, :journal_details,
|
||||
:users, :members, :member_roles, :roles, :projects_trackers, :trackers, :boards,
|
||||
:queries
|
||||
|
||||
def setup
|
||||
@ecookbook = Project.find(1)
|
||||
@ecookbook_sub1 = Project.find(3)
|
||||
end
|
||||
|
||||
def test_truth
|
||||
assert_kind_of Project, @ecookbook
|
||||
assert_equal "eCookbook", @ecookbook.name
|
||||
end
|
||||
|
||||
def test_update
|
||||
assert_equal "eCookbook", @ecookbook.name
|
||||
@ecookbook.name = "eCook"
|
||||
assert @ecookbook.save, @ecookbook.errors.full_messages.join("; ")
|
||||
@ecookbook.reload
|
||||
assert_equal "eCook", @ecookbook.name
|
||||
end
|
||||
|
||||
def test_validate
|
||||
@ecookbook.name = ""
|
||||
assert !@ecookbook.save
|
||||
assert_equal 1, @ecookbook.errors.count
|
||||
assert_equal I18n.translate('activerecord.errors.messages.blank'), @ecookbook.errors.on(:name)
|
||||
end
|
||||
|
||||
def test_validate_identifier
|
||||
to_test = {"abc" => true,
|
||||
"ab12" => true,
|
||||
"ab-12" => true,
|
||||
"12" => false,
|
||||
"new" => false}
|
||||
|
||||
to_test.each do |identifier, valid|
|
||||
p = Project.new
|
||||
p.identifier = identifier
|
||||
p.valid?
|
||||
assert_equal valid, p.errors.on('identifier').nil?
|
||||
end
|
||||
end
|
||||
|
||||
def test_members_should_be_active_users
|
||||
Project.all.each do |project|
|
||||
assert_nil project.members.detect {|m| !(m.user.is_a?(User) && m.user.active?) }
|
||||
end
|
||||
end
|
||||
|
||||
def test_users_should_be_active_users
|
||||
Project.all.each do |project|
|
||||
assert_nil project.users.detect {|u| !(u.is_a?(User) && u.active?) }
|
||||
end
|
||||
end
|
||||
|
||||
def test_archive
|
||||
user = @ecookbook.members.first.user
|
||||
@ecookbook.archive
|
||||
@ecookbook.reload
|
||||
|
||||
assert !@ecookbook.active?
|
||||
assert !user.projects.include?(@ecookbook)
|
||||
# Subproject are also archived
|
||||
assert !@ecookbook.children.empty?
|
||||
assert @ecookbook.descendants.active.empty?
|
||||
end
|
||||
|
||||
def test_unarchive
|
||||
user = @ecookbook.members.first.user
|
||||
@ecookbook.archive
|
||||
# A subproject of an archived project can not be unarchived
|
||||
assert !@ecookbook_sub1.unarchive
|
||||
|
||||
# Unarchive project
|
||||
assert @ecookbook.unarchive
|
||||
@ecookbook.reload
|
||||
assert @ecookbook.active?
|
||||
assert user.projects.include?(@ecookbook)
|
||||
# Subproject can now be unarchived
|
||||
@ecookbook_sub1.reload
|
||||
assert @ecookbook_sub1.unarchive
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
# 2 active members
|
||||
assert_equal 2, @ecookbook.members.size
|
||||
# and 1 is locked
|
||||
assert_equal 3, Member.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).size
|
||||
# some boards
|
||||
assert @ecookbook.boards.any?
|
||||
|
||||
@ecookbook.destroy
|
||||
# make sure that the project non longer exists
|
||||
assert_raise(ActiveRecord::RecordNotFound) { Project.find(@ecookbook.id) }
|
||||
# make sure related data was removed
|
||||
assert Member.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).empty?
|
||||
assert Board.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).empty?
|
||||
end
|
||||
|
||||
def test_move_an_orphan_project_to_a_root_project
|
||||
sub = Project.find(2)
|
||||
sub.set_parent! @ecookbook
|
||||
assert_equal @ecookbook.id, sub.parent.id
|
||||
@ecookbook.reload
|
||||
assert_equal 4, @ecookbook.children.size
|
||||
end
|
||||
|
||||
def test_move_an_orphan_project_to_a_subproject
|
||||
sub = Project.find(2)
|
||||
assert sub.set_parent!(@ecookbook_sub1)
|
||||
end
|
||||
|
||||
def test_move_a_root_project_to_a_project
|
||||
sub = @ecookbook
|
||||
assert sub.set_parent!(Project.find(2))
|
||||
end
|
||||
|
||||
def test_should_not_move_a_project_to_its_children
|
||||
sub = @ecookbook
|
||||
assert !(sub.set_parent!(Project.find(3)))
|
||||
end
|
||||
|
||||
def test_set_parent_should_add_roots_in_alphabetical_order
|
||||
ProjectCustomField.delete_all
|
||||
Project.delete_all
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').set_parent!(nil)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').set_parent!(nil)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').set_parent!(nil)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').set_parent!(nil)
|
||||
|
||||
assert_equal 4, Project.count
|
||||
assert_equal Project.all.sort_by(&:name), Project.all.sort_by(&:lft)
|
||||
end
|
||||
|
||||
def test_set_parent_should_add_children_in_alphabetical_order
|
||||
ProjectCustomField.delete_all
|
||||
parent = Project.create!(:name => 'Parent', :identifier => 'parent')
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').set_parent!(parent)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').set_parent!(parent)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').set_parent!(parent)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').set_parent!(parent)
|
||||
|
||||
parent.reload
|
||||
assert_equal 4, parent.children.size
|
||||
assert_equal parent.children.sort_by(&:name), parent.children
|
||||
end
|
||||
|
||||
def test_rebuild_should_sort_children_alphabetically
|
||||
ProjectCustomField.delete_all
|
||||
parent = Project.create!(:name => 'Parent', :identifier => 'parent')
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').move_to_child_of(parent)
|
||||
|
||||
Project.update_all("lft = NULL, rgt = NULL")
|
||||
Project.rebuild!
|
||||
|
||||
parent.reload
|
||||
assert_equal 4, parent.children.size
|
||||
assert_equal parent.children.sort_by(&:name), parent.children
|
||||
end
|
||||
|
||||
def test_parent
|
||||
p = Project.find(6).parent
|
||||
assert p.is_a?(Project)
|
||||
assert_equal 5, p.id
|
||||
end
|
||||
|
||||
def test_ancestors
|
||||
a = Project.find(6).ancestors
|
||||
assert a.first.is_a?(Project)
|
||||
assert_equal [1, 5], a.collect(&:id)
|
||||
end
|
||||
|
||||
def test_root
|
||||
r = Project.find(6).root
|
||||
assert r.is_a?(Project)
|
||||
assert_equal 1, r.id
|
||||
end
|
||||
|
||||
def test_children
|
||||
c = Project.find(1).children
|
||||
assert c.first.is_a?(Project)
|
||||
assert_equal [5, 3, 4], c.collect(&:id)
|
||||
end
|
||||
|
||||
def test_descendants
|
||||
d = Project.find(1).descendants
|
||||
assert d.first.is_a?(Project)
|
||||
assert_equal [5, 6, 3, 4], d.collect(&:id)
|
||||
end
|
||||
|
||||
def test_users_by_role
|
||||
users_by_role = Project.find(1).users_by_role
|
||||
assert_kind_of Hash, users_by_role
|
||||
role = Role.find(1)
|
||||
assert_kind_of Array, users_by_role[role]
|
||||
assert users_by_role[role].include?(User.find(2))
|
||||
end
|
||||
|
||||
def test_rolled_up_trackers
|
||||
parent = Project.find(1)
|
||||
parent.trackers = Tracker.find([1,2])
|
||||
child = parent.children.find(3)
|
||||
|
||||
assert_equal [1, 2], parent.tracker_ids
|
||||
assert_equal [2, 3], child.trackers.collect(&:id)
|
||||
|
||||
assert_kind_of Tracker, parent.rolled_up_trackers.first
|
||||
assert_equal Tracker.find(1), parent.rolled_up_trackers.first
|
||||
|
||||
assert_equal [1, 2, 3], parent.rolled_up_trackers.collect(&:id)
|
||||
assert_equal [2, 3], child.rolled_up_trackers.collect(&:id)
|
||||
end
|
||||
|
||||
def test_rolled_up_trackers_should_ignore_archived_subprojects
|
||||
parent = Project.find(1)
|
||||
parent.trackers = Tracker.find([1,2])
|
||||
child = parent.children.find(3)
|
||||
child.trackers = Tracker.find([1,3])
|
||||
parent.children.each(&:archive)
|
||||
|
||||
assert_equal [1,2], parent.rolled_up_trackers.collect(&:id)
|
||||
end
|
||||
|
||||
def test_next_identifier
|
||||
ProjectCustomField.delete_all
|
||||
Project.create!(:name => 'last', :identifier => 'p2008040')
|
||||
assert_equal 'p2008041', Project.next_identifier
|
||||
end
|
||||
|
||||
def test_next_identifier_first_project
|
||||
Project.delete_all
|
||||
assert_nil Project.next_identifier
|
||||
end
|
||||
|
||||
# redMine - project management software
|
||||
# Copyright (C) 2006-2007 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
def test_enabled_module_names_should_not_recreate_enabled_modules
|
||||
project = Project.find(1)
|
||||
# Remove one module
|
||||
modules = project.enabled_modules.slice(0..-2)
|
||||
assert modules.any?
|
||||
assert_difference 'EnabledModule.count', -1 do
|
||||
project.enabled_module_names = modules.collect(&:name)
|
||||
end
|
||||
project.reload
|
||||
# Ids should be preserved
|
||||
assert_equal project.enabled_module_ids.sort, modules.collect(&:id).sort
|
||||
end
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
|
||||
def test_copy_from_existing_project
|
||||
source_project = Project.find(1)
|
||||
copied_project = Project.copy_from(1)
|
||||
|
||||
assert copied_project
|
||||
# Cleared attributes
|
||||
assert copied_project.id.blank?
|
||||
assert copied_project.name.blank?
|
||||
assert copied_project.identifier.blank?
|
||||
|
||||
# Duplicated attributes
|
||||
assert_equal source_project.description, copied_project.description
|
||||
assert_equal source_project.enabled_modules, copied_project.enabled_modules
|
||||
assert_equal source_project.trackers, copied_project.trackers
|
||||
|
||||
# Default attributes
|
||||
assert_equal 1, copied_project.status
|
||||
end
|
||||
|
||||
# Context: Project#copy
|
||||
def test_copy_should_copy_issues
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
Project.destroy_all :identifier => "copy-test"
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
assert project.valid?
|
||||
|
||||
assert project.issues.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.issues.size, project.issues.size
|
||||
project.issues.each do |issue|
|
||||
assert issue.valid?
|
||||
assert ! issue.assigned_to.blank?
|
||||
assert_equal project, issue.project
|
||||
end
|
||||
end
|
||||
|
||||
def test_copy_should_copy_members
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
project.enabled_modules = source_project.enabled_modules
|
||||
assert project.valid?
|
||||
|
||||
assert project.members.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.members.size, project.members.size
|
||||
project.members.each do |member|
|
||||
assert member
|
||||
assert_equal project, member.project
|
||||
end
|
||||
end
|
||||
|
||||
def test_copy_should_copy_project_level_queries
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
project.enabled_modules = source_project.enabled_modules
|
||||
assert project.valid?
|
||||
|
||||
assert project.queries.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.queries.size, project.queries.size
|
||||
project.queries.each do |query|
|
||||
assert query
|
||||
assert_equal project, query.project
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
class ProjectTest < ActiveSupport::TestCase
|
||||
fixtures :projects, :enabled_modules,
|
||||
:issues, :issue_statuses, :journals, :journal_details,
|
||||
:users, :members, :member_roles, :roles, :projects_trackers, :trackers, :boards,
|
||||
:queries
|
||||
|
||||
def setup
|
||||
@ecookbook = Project.find(1)
|
||||
@ecookbook_sub1 = Project.find(3)
|
||||
end
|
||||
|
||||
def test_truth
|
||||
assert_kind_of Project, @ecookbook
|
||||
assert_equal "eCookbook", @ecookbook.name
|
||||
end
|
||||
|
||||
def test_update
|
||||
assert_equal "eCookbook", @ecookbook.name
|
||||
@ecookbook.name = "eCook"
|
||||
assert @ecookbook.save, @ecookbook.errors.full_messages.join("; ")
|
||||
@ecookbook.reload
|
||||
assert_equal "eCook", @ecookbook.name
|
||||
end
|
||||
|
||||
def test_validate
|
||||
@ecookbook.name = ""
|
||||
assert !@ecookbook.save
|
||||
assert_equal 1, @ecookbook.errors.count
|
||||
assert_equal I18n.translate('activerecord.errors.messages.blank'), @ecookbook.errors.on(:name)
|
||||
end
|
||||
|
||||
def test_validate_identifier
|
||||
to_test = {"abc" => true,
|
||||
"ab12" => true,
|
||||
"ab-12" => true,
|
||||
"12" => false,
|
||||
"new" => false}
|
||||
|
||||
to_test.each do |identifier, valid|
|
||||
p = Project.new
|
||||
p.identifier = identifier
|
||||
p.valid?
|
||||
assert_equal valid, p.errors.on('identifier').nil?
|
||||
end
|
||||
end
|
||||
|
||||
def test_members_should_be_active_users
|
||||
Project.all.each do |project|
|
||||
assert_nil project.members.detect {|m| !(m.user.is_a?(User) && m.user.active?) }
|
||||
end
|
||||
end
|
||||
|
||||
def test_users_should_be_active_users
|
||||
Project.all.each do |project|
|
||||
assert_nil project.users.detect {|u| !(u.is_a?(User) && u.active?) }
|
||||
end
|
||||
end
|
||||
|
||||
def test_archive
|
||||
user = @ecookbook.members.first.user
|
||||
@ecookbook.archive
|
||||
@ecookbook.reload
|
||||
|
||||
assert !@ecookbook.active?
|
||||
assert !user.projects.include?(@ecookbook)
|
||||
# Subproject are also archived
|
||||
assert !@ecookbook.children.empty?
|
||||
assert @ecookbook.descendants.active.empty?
|
||||
end
|
||||
|
||||
def test_unarchive
|
||||
user = @ecookbook.members.first.user
|
||||
@ecookbook.archive
|
||||
# A subproject of an archived project can not be unarchived
|
||||
assert !@ecookbook_sub1.unarchive
|
||||
|
||||
# Unarchive project
|
||||
assert @ecookbook.unarchive
|
||||
@ecookbook.reload
|
||||
assert @ecookbook.active?
|
||||
assert user.projects.include?(@ecookbook)
|
||||
# Subproject can now be unarchived
|
||||
@ecookbook_sub1.reload
|
||||
assert @ecookbook_sub1.unarchive
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
# 2 active members
|
||||
assert_equal 2, @ecookbook.members.size
|
||||
# and 1 is locked
|
||||
assert_equal 3, Member.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).size
|
||||
# some boards
|
||||
assert @ecookbook.boards.any?
|
||||
|
||||
@ecookbook.destroy
|
||||
# make sure that the project non longer exists
|
||||
assert_raise(ActiveRecord::RecordNotFound) { Project.find(@ecookbook.id) }
|
||||
# make sure related data was removed
|
||||
assert Member.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).empty?
|
||||
assert Board.find(:all, :conditions => ['project_id = ?', @ecookbook.id]).empty?
|
||||
end
|
||||
|
||||
def test_move_an_orphan_project_to_a_root_project
|
||||
sub = Project.find(2)
|
||||
sub.set_parent! @ecookbook
|
||||
assert_equal @ecookbook.id, sub.parent.id
|
||||
@ecookbook.reload
|
||||
assert_equal 4, @ecookbook.children.size
|
||||
end
|
||||
|
||||
def test_move_an_orphan_project_to_a_subproject
|
||||
sub = Project.find(2)
|
||||
assert sub.set_parent!(@ecookbook_sub1)
|
||||
end
|
||||
|
||||
def test_move_a_root_project_to_a_project
|
||||
sub = @ecookbook
|
||||
assert sub.set_parent!(Project.find(2))
|
||||
end
|
||||
|
||||
def test_should_not_move_a_project_to_its_children
|
||||
sub = @ecookbook
|
||||
assert !(sub.set_parent!(Project.find(3)))
|
||||
end
|
||||
|
||||
def test_set_parent_should_add_roots_in_alphabetical_order
|
||||
ProjectCustomField.delete_all
|
||||
Project.delete_all
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').set_parent!(nil)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').set_parent!(nil)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').set_parent!(nil)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').set_parent!(nil)
|
||||
|
||||
assert_equal 4, Project.count
|
||||
assert_equal Project.all.sort_by(&:name), Project.all.sort_by(&:lft)
|
||||
end
|
||||
|
||||
def test_set_parent_should_add_children_in_alphabetical_order
|
||||
ProjectCustomField.delete_all
|
||||
parent = Project.create!(:name => 'Parent', :identifier => 'parent')
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').set_parent!(parent)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').set_parent!(parent)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').set_parent!(parent)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').set_parent!(parent)
|
||||
|
||||
parent.reload
|
||||
assert_equal 4, parent.children.size
|
||||
assert_equal parent.children.sort_by(&:name), parent.children
|
||||
end
|
||||
|
||||
def test_rebuild_should_sort_children_alphabetically
|
||||
ProjectCustomField.delete_all
|
||||
parent = Project.create!(:name => 'Parent', :identifier => 'parent')
|
||||
Project.create!(:name => 'Project C', :identifier => 'project-c').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project B', :identifier => 'project-b').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project D', :identifier => 'project-d').move_to_child_of(parent)
|
||||
Project.create!(:name => 'Project A', :identifier => 'project-a').move_to_child_of(parent)
|
||||
|
||||
Project.update_all("lft = NULL, rgt = NULL")
|
||||
Project.rebuild!
|
||||
|
||||
parent.reload
|
||||
assert_equal 4, parent.children.size
|
||||
assert_equal parent.children.sort_by(&:name), parent.children
|
||||
end
|
||||
|
||||
def test_parent
|
||||
p = Project.find(6).parent
|
||||
assert p.is_a?(Project)
|
||||
assert_equal 5, p.id
|
||||
end
|
||||
|
||||
def test_ancestors
|
||||
a = Project.find(6).ancestors
|
||||
assert a.first.is_a?(Project)
|
||||
assert_equal [1, 5], a.collect(&:id)
|
||||
end
|
||||
|
||||
def test_root
|
||||
r = Project.find(6).root
|
||||
assert r.is_a?(Project)
|
||||
assert_equal 1, r.id
|
||||
end
|
||||
|
||||
def test_children
|
||||
c = Project.find(1).children
|
||||
assert c.first.is_a?(Project)
|
||||
assert_equal [5, 3, 4], c.collect(&:id)
|
||||
end
|
||||
|
||||
def test_descendants
|
||||
d = Project.find(1).descendants
|
||||
assert d.first.is_a?(Project)
|
||||
assert_equal [5, 6, 3, 4], d.collect(&:id)
|
||||
end
|
||||
|
||||
def test_users_by_role
|
||||
users_by_role = Project.find(1).users_by_role
|
||||
assert_kind_of Hash, users_by_role
|
||||
role = Role.find(1)
|
||||
assert_kind_of Array, users_by_role[role]
|
||||
assert users_by_role[role].include?(User.find(2))
|
||||
end
|
||||
|
||||
def test_rolled_up_trackers
|
||||
parent = Project.find(1)
|
||||
parent.trackers = Tracker.find([1,2])
|
||||
child = parent.children.find(3)
|
||||
|
||||
assert_equal [1, 2], parent.tracker_ids
|
||||
assert_equal [2, 3], child.trackers.collect(&:id)
|
||||
|
||||
assert_kind_of Tracker, parent.rolled_up_trackers.first
|
||||
assert_equal Tracker.find(1), parent.rolled_up_trackers.first
|
||||
|
||||
assert_equal [1, 2, 3], parent.rolled_up_trackers.collect(&:id)
|
||||
assert_equal [2, 3], child.rolled_up_trackers.collect(&:id)
|
||||
end
|
||||
|
||||
def test_rolled_up_trackers_should_ignore_archived_subprojects
|
||||
parent = Project.find(1)
|
||||
parent.trackers = Tracker.find([1,2])
|
||||
child = parent.children.find(3)
|
||||
child.trackers = Tracker.find([1,3])
|
||||
parent.children.each(&:archive)
|
||||
|
||||
assert_equal [1,2], parent.rolled_up_trackers.collect(&:id)
|
||||
end
|
||||
|
||||
def test_next_identifier
|
||||
ProjectCustomField.delete_all
|
||||
Project.create!(:name => 'last', :identifier => 'p2008040')
|
||||
assert_equal 'p2008041', Project.next_identifier
|
||||
end
|
||||
|
||||
def test_next_identifier_first_project
|
||||
Project.delete_all
|
||||
assert_nil Project.next_identifier
|
||||
end
|
||||
|
||||
|
||||
def test_enabled_module_names_should_not_recreate_enabled_modules
|
||||
project = Project.find(1)
|
||||
# Remove one module
|
||||
modules = project.enabled_modules.slice(0..-2)
|
||||
assert modules.any?
|
||||
assert_difference 'EnabledModule.count', -1 do
|
||||
project.enabled_module_names = modules.collect(&:name)
|
||||
end
|
||||
project.reload
|
||||
# Ids should be preserved
|
||||
assert_equal project.enabled_module_ids.sort, modules.collect(&:id).sort
|
||||
end
|
||||
|
||||
def test_copy_from_existing_project
|
||||
source_project = Project.find(1)
|
||||
copied_project = Project.copy_from(1)
|
||||
|
||||
assert copied_project
|
||||
# Cleared attributes
|
||||
assert copied_project.id.blank?
|
||||
assert copied_project.name.blank?
|
||||
assert copied_project.identifier.blank?
|
||||
|
||||
# Duplicated attributes
|
||||
assert_equal source_project.description, copied_project.description
|
||||
assert_equal source_project.enabled_modules, copied_project.enabled_modules
|
||||
assert_equal source_project.trackers, copied_project.trackers
|
||||
|
||||
# Default attributes
|
||||
assert_equal 1, copied_project.status
|
||||
end
|
||||
|
||||
# Context: Project#copy
|
||||
def test_copy_should_copy_issues
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
Project.destroy_all :identifier => "copy-test"
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
assert project.valid?
|
||||
|
||||
assert project.issues.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.issues.size, project.issues.size
|
||||
project.issues.each do |issue|
|
||||
assert issue.valid?
|
||||
assert ! issue.assigned_to.blank?
|
||||
assert_equal project, issue.project
|
||||
end
|
||||
end
|
||||
|
||||
def test_copy_should_copy_members
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
project.enabled_modules = source_project.enabled_modules
|
||||
assert project.valid?
|
||||
|
||||
assert project.members.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.members.size, project.members.size
|
||||
project.members.each do |member|
|
||||
assert member
|
||||
assert_equal project, member.project
|
||||
end
|
||||
end
|
||||
|
||||
def test_copy_should_copy_project_level_queries
|
||||
# Setup
|
||||
ProjectCustomField.destroy_all # Custom values are a mess to isolate in tests
|
||||
source_project = Project.find(2)
|
||||
project = Project.new(:name => 'Copy Test', :identifier => 'copy-test')
|
||||
project.trackers = source_project.trackers
|
||||
project.enabled_modules = source_project.enabled_modules
|
||||
assert project.valid?
|
||||
|
||||
assert project.queries.empty?
|
||||
assert project.copy(source_project)
|
||||
|
||||
# Tests
|
||||
assert_equal source_project.queries.size, project.queries.size
|
||||
project.queries.each do |query|
|
||||
assert query
|
||||
assert_equal project, query.project
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
@ -32,17 +32,17 @@ class RepositoryTest < ActiveSupport::TestCase
|
|||
def setup
|
||||
@repository = Project.find(1).repository
|
||||
end
|
||||
|
||||
def test_create
|
||||
|
||||
def test_create
|
||||
repository = Repository::Subversion.new(:project => Project.find(3))
|
||||
assert !repository.save
|
||||
|
||||
repository.url = "svn://localhost"
|
||||
repository.url = "svn://localhost"
|
||||
assert repository.save
|
||||
repository.reload
|
||||
|
||||
project = Project.find(3)
|
||||
assert_equal repository, project.repository
|
||||
assert_equal repository, project.repository
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
|
|
|
@ -1,223 +1,223 @@
|
|||
# redMine - project management software
|
||||
# Copyright (C) 2006 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
|
||||
class UserTest < ActiveSupport::TestCase
|
||||
fixtures :users, :members, :projects, :roles, :member_roles
|
||||
|
||||
def setup
|
||||
@admin = User.find(1)
|
||||
@jsmith = User.find(2)
|
||||
@dlopper = User.find(3)
|
||||
end
|
||||
|
||||
def test_truth
|
||||
assert_kind_of User, @jsmith
|
||||
end
|
||||
|
||||
def test_create
|
||||
user = User.new(:firstname => "new", :lastname => "user", :mail => "newuser@somenet.foo")
|
||||
|
||||
user.login = "jsmith"
|
||||
user.password, user.password_confirmation = "password", "password"
|
||||
# login uniqueness
|
||||
assert !user.save
|
||||
assert_equal 1, user.errors.count
|
||||
|
||||
user.login = "newuser"
|
||||
user.password, user.password_confirmation = "passwd", "password"
|
||||
# password confirmation
|
||||
assert !user.save
|
||||
assert_equal 1, user.errors.count
|
||||
|
||||
user.password, user.password_confirmation = "password", "password"
|
||||
assert user.save
|
||||
end
|
||||
|
||||
def test_mail_uniqueness_should_not_be_case_sensitive
|
||||
u = User.new(:firstname => "new", :lastname => "user", :mail => "newuser@somenet.foo")
|
||||
u.login = 'newuser1'
|
||||
u.password, u.password_confirmation = "password", "password"
|
||||
assert u.save
|
||||
|
||||
u = User.new(:firstname => "new", :lastname => "user", :mail => "newUser@Somenet.foo")
|
||||
u.login = 'newuser2'
|
||||
u.password, u.password_confirmation = "password", "password"
|
||||
assert !u.save
|
||||
assert_equal I18n.translate('activerecord.errors.messages.taken'), u.errors.on(:mail)
|
||||
end
|
||||
|
||||
def test_update
|
||||
assert_equal "admin", @admin.login
|
||||
@admin.login = "john"
|
||||
assert @admin.save, @admin.errors.full_messages.join("; ")
|
||||
@admin.reload
|
||||
assert_equal "john", @admin.login
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
User.find(2).destroy
|
||||
assert_nil User.find_by_id(2)
|
||||
assert Member.find_all_by_user_id(2).empty?
|
||||
end
|
||||
|
||||
def test_validate
|
||||
@admin.login = ""
|
||||
assert !@admin.save
|
||||
assert_equal 1, @admin.errors.count
|
||||
end
|
||||
|
||||
def test_password
|
||||
user = User.try_to_login("admin", "admin")
|
||||
assert_kind_of User, user
|
||||
assert_equal "admin", user.login
|
||||
user.password = "hello"
|
||||
assert user.save
|
||||
|
||||
user = User.try_to_login("admin", "hello")
|
||||
assert_kind_of User, user
|
||||
assert_equal "admin", user.login
|
||||
assert_equal User.hash_password("hello"), user.hashed_password
|
||||
end
|
||||
|
||||
def test_name_format
|
||||
assert_equal 'Smith, John', @jsmith.name(:lastname_coma_firstname)
|
||||
Setting.user_format = :firstname_lastname
|
||||
assert_equal 'John Smith', @jsmith.reload.name
|
||||
Setting.user_format = :username
|
||||
assert_equal 'jsmith', @jsmith.reload.name
|
||||
end
|
||||
|
||||
def test_lock
|
||||
user = User.try_to_login("jsmith", "jsmith")
|
||||
assert_equal @jsmith, user
|
||||
|
||||
@jsmith.status = User::STATUS_LOCKED
|
||||
assert @jsmith.save
|
||||
|
||||
user = User.try_to_login("jsmith", "jsmith")
|
||||
assert_equal nil, user
|
||||
end
|
||||
|
||||
def test_create_anonymous
|
||||
AnonymousUser.delete_all
|
||||
anon = User.anonymous
|
||||
assert !anon.new_record?
|
||||
assert_kind_of AnonymousUser, anon
|
||||
end
|
||||
|
||||
def test_rss_key
|
||||
assert_nil @jsmith.rss_token
|
||||
key = @jsmith.rss_key
|
||||
assert_equal 40, key.length
|
||||
|
||||
@jsmith.reload
|
||||
assert_equal key, @jsmith.rss_key
|
||||
end
|
||||
|
||||
def test_roles_for_project
|
||||
# user with a role
|
||||
roles = @jsmith.roles_for_project(Project.find(1))
|
||||
assert_kind_of Role, roles.first
|
||||
assert_equal "Manager", roles.first.name
|
||||
|
||||
# user with no role
|
||||
assert_nil @dlopper.roles_for_project(Project.find(2)).detect {|role| role.member?}
|
||||
end
|
||||
|
||||
def test_mail_notification_all
|
||||
@jsmith.mail_notification = true
|
||||
@jsmith.notified_project_ids = []
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert @jsmith.projects.first.recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_mail_notification_selected
|
||||
@jsmith.mail_notification = false
|
||||
@jsmith.notified_project_ids = [1]
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert Project.find(1).recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_mail_notification_none
|
||||
@jsmith.mail_notification = false
|
||||
@jsmith.notified_project_ids = []
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert !@jsmith.projects.first.recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_comments_sorting_preference
|
||||
assert !@jsmith.wants_comments_in_reverse_order?
|
||||
@jsmith.pref.comments_sorting = 'asc'
|
||||
assert !@jsmith.wants_comments_in_reverse_order?
|
||||
@jsmith.pref.comments_sorting = 'desc'
|
||||
assert @jsmith.wants_comments_in_reverse_order?
|
||||
end
|
||||
|
||||
def test_find_by_mail_should_be_case_insensitive
|
||||
u = User.find_by_mail('JSmith@somenet.foo')
|
||||
assert_not_nil u
|
||||
assert_equal 'jsmith@somenet.foo', u.mail
|
||||
end
|
||||
|
||||
def test_random_password
|
||||
u = User.new
|
||||
u.random_password
|
||||
assert !u.password.blank?
|
||||
assert !u.password_confirmation.blank?
|
||||
end
|
||||
|
||||
if Object.const_defined?(:OpenID)
|
||||
|
||||
def test_setting_identity_url
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'http://example.com/' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_identity_url_without_trailing_slash
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'http://example.com' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_identity_url_without_protocol
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'example.com' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_blank_identity_url
|
||||
u = User.new( :identity_url => 'example.com' )
|
||||
u.identity_url = ''
|
||||
assert u.identity_url.blank?
|
||||
end
|
||||
|
||||
def test_setting_invalid_identity_url
|
||||
u = User.new( :identity_url => 'this is not an openid url' )
|
||||
assert u.identity_url.blank?
|
||||
end
|
||||
|
||||
else
|
||||
puts "Skipping openid tests."
|
||||
end
|
||||
|
||||
end
|
||||
# redMine - project management software
|
||||
# Copyright (C) 2006 Jean-Philippe Lang
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
|
||||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
|
||||
class UserTest < ActiveSupport::TestCase
|
||||
fixtures :users, :members, :projects, :roles, :member_roles
|
||||
|
||||
def setup
|
||||
@admin = User.find(1)
|
||||
@jsmith = User.find(2)
|
||||
@dlopper = User.find(3)
|
||||
end
|
||||
|
||||
def test_truth
|
||||
assert_kind_of User, @jsmith
|
||||
end
|
||||
|
||||
def test_create
|
||||
user = User.new(:firstname => "new", :lastname => "user", :mail => "newuser@somenet.foo")
|
||||
|
||||
user.login = "jsmith"
|
||||
user.password, user.password_confirmation = "password", "password"
|
||||
# login uniqueness
|
||||
assert !user.save
|
||||
assert_equal 1, user.errors.count
|
||||
|
||||
user.login = "newuser"
|
||||
user.password, user.password_confirmation = "passwd", "password"
|
||||
# password confirmation
|
||||
assert !user.save
|
||||
assert_equal 1, user.errors.count
|
||||
|
||||
user.password, user.password_confirmation = "password", "password"
|
||||
assert user.save
|
||||
end
|
||||
|
||||
def test_mail_uniqueness_should_not_be_case_sensitive
|
||||
u = User.new(:firstname => "new", :lastname => "user", :mail => "newuser@somenet.foo")
|
||||
u.login = 'newuser1'
|
||||
u.password, u.password_confirmation = "password", "password"
|
||||
assert u.save
|
||||
|
||||
u = User.new(:firstname => "new", :lastname => "user", :mail => "newUser@Somenet.foo")
|
||||
u.login = 'newuser2'
|
||||
u.password, u.password_confirmation = "password", "password"
|
||||
assert !u.save
|
||||
assert_equal I18n.translate('activerecord.errors.messages.taken'), u.errors.on(:mail)
|
||||
end
|
||||
|
||||
def test_update
|
||||
assert_equal "admin", @admin.login
|
||||
@admin.login = "john"
|
||||
assert @admin.save, @admin.errors.full_messages.join("; ")
|
||||
@admin.reload
|
||||
assert_equal "john", @admin.login
|
||||
end
|
||||
|
||||
def test_destroy
|
||||
User.find(2).destroy
|
||||
assert_nil User.find_by_id(2)
|
||||
assert Member.find_all_by_user_id(2).empty?
|
||||
end
|
||||
|
||||
def test_validate
|
||||
@admin.login = ""
|
||||
assert !@admin.save
|
||||
assert_equal 1, @admin.errors.count
|
||||
end
|
||||
|
||||
def test_password
|
||||
user = User.try_to_login("admin", "admin")
|
||||
assert_kind_of User, user
|
||||
assert_equal "admin", user.login
|
||||
user.password = "hello"
|
||||
assert user.save
|
||||
|
||||
user = User.try_to_login("admin", "hello")
|
||||
assert_kind_of User, user
|
||||
assert_equal "admin", user.login
|
||||
assert_equal User.hash_password("hello"), user.hashed_password
|
||||
end
|
||||
|
||||
def test_name_format
|
||||
assert_equal 'Smith, John', @jsmith.name(:lastname_coma_firstname)
|
||||
Setting.user_format = :firstname_lastname
|
||||
assert_equal 'John Smith', @jsmith.reload.name
|
||||
Setting.user_format = :username
|
||||
assert_equal 'jsmith', @jsmith.reload.name
|
||||
end
|
||||
|
||||
def test_lock
|
||||
user = User.try_to_login("jsmith", "jsmith")
|
||||
assert_equal @jsmith, user
|
||||
|
||||
@jsmith.status = User::STATUS_LOCKED
|
||||
assert @jsmith.save
|
||||
|
||||
user = User.try_to_login("jsmith", "jsmith")
|
||||
assert_equal nil, user
|
||||
end
|
||||
|
||||
def test_create_anonymous
|
||||
AnonymousUser.delete_all
|
||||
anon = User.anonymous
|
||||
assert !anon.new_record?
|
||||
assert_kind_of AnonymousUser, anon
|
||||
end
|
||||
|
||||
def test_rss_key
|
||||
assert_nil @jsmith.rss_token
|
||||
key = @jsmith.rss_key
|
||||
assert_equal 40, key.length
|
||||
|
||||
@jsmith.reload
|
||||
assert_equal key, @jsmith.rss_key
|
||||
end
|
||||
|
||||
def test_roles_for_project
|
||||
# user with a role
|
||||
roles = @jsmith.roles_for_project(Project.find(1))
|
||||
assert_kind_of Role, roles.first
|
||||
assert_equal "Manager", roles.first.name
|
||||
|
||||
# user with no role
|
||||
assert_nil @dlopper.roles_for_project(Project.find(2)).detect {|role| role.member?}
|
||||
end
|
||||
|
||||
def test_mail_notification_all
|
||||
@jsmith.mail_notification = true
|
||||
@jsmith.notified_project_ids = []
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert @jsmith.projects.first.recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_mail_notification_selected
|
||||
@jsmith.mail_notification = false
|
||||
@jsmith.notified_project_ids = [1]
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert Project.find(1).recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_mail_notification_none
|
||||
@jsmith.mail_notification = false
|
||||
@jsmith.notified_project_ids = []
|
||||
@jsmith.save
|
||||
@jsmith.reload
|
||||
assert !@jsmith.projects.first.recipients.include?(@jsmith.mail)
|
||||
end
|
||||
|
||||
def test_comments_sorting_preference
|
||||
assert !@jsmith.wants_comments_in_reverse_order?
|
||||
@jsmith.pref.comments_sorting = 'asc'
|
||||
assert !@jsmith.wants_comments_in_reverse_order?
|
||||
@jsmith.pref.comments_sorting = 'desc'
|
||||
assert @jsmith.wants_comments_in_reverse_order?
|
||||
end
|
||||
|
||||
def test_find_by_mail_should_be_case_insensitive
|
||||
u = User.find_by_mail('JSmith@somenet.foo')
|
||||
assert_not_nil u
|
||||
assert_equal 'jsmith@somenet.foo', u.mail
|
||||
end
|
||||
|
||||
def test_random_password
|
||||
u = User.new
|
||||
u.random_password
|
||||
assert !u.password.blank?
|
||||
assert !u.password_confirmation.blank?
|
||||
end
|
||||
|
||||
if Object.const_defined?(:OpenID)
|
||||
|
||||
def test_setting_identity_url
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'http://example.com/' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_identity_url_without_trailing_slash
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'http://example.com' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_identity_url_without_protocol
|
||||
normalized_open_id_url = 'http://example.com/'
|
||||
u = User.new( :identity_url => 'example.com' )
|
||||
assert_equal normalized_open_id_url, u.identity_url
|
||||
end
|
||||
|
||||
def test_setting_blank_identity_url
|
||||
u = User.new( :identity_url => 'example.com' )
|
||||
u.identity_url = ''
|
||||
assert u.identity_url.blank?
|
||||
end
|
||||
|
||||
def test_setting_invalid_identity_url
|
||||
u = User.new( :identity_url => 'this is not an openid url' )
|
||||
assert u.identity_url.blank?
|
||||
end
|
||||
|
||||
else
|
||||
puts "Skipping openid tests."
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
@ -24,18 +24,18 @@ class WikiPageTest < ActiveSupport::TestCase
|
|||
@wiki = Wiki.find(1)
|
||||
@page = @wiki.pages.first
|
||||
end
|
||||
|
||||
def test_create
|
||||
|
||||
def test_create
|
||||
page = WikiPage.new(:wiki => @wiki)
|
||||
assert !page.save
|
||||
assert_equal 1, page.errors.count
|
||||
|
||||
page.title = "Page"
|
||||
page.title = "Page"
|
||||
assert page.save
|
||||
page.reload
|
||||
|
||||
@wiki.reload
|
||||
assert @wiki.pages.include?(page)
|
||||
assert @wiki.pages.include?(page)
|
||||
end
|
||||
|
||||
def test_find_or_new_page
|
||||
|
|
|
@ -19,15 +19,15 @@ require File.dirname(__FILE__) + '/../test_helper'
|
|||
|
||||
class WikiTest < ActiveSupport::TestCase
|
||||
fixtures :wikis, :wiki_pages, :wiki_contents, :wiki_content_versions
|
||||
|
||||
def test_create
|
||||
|
||||
def test_create
|
||||
wiki = Wiki.new(:project => Project.find(2))
|
||||
assert !wiki.save
|
||||
assert_equal 1, wiki.errors.count
|
||||
|
||||
wiki.start_page = "Start page"
|
||||
assert wiki.save
|
||||
end
|
||||
wiki.start_page = "Start page"
|
||||
assert wiki.save
|
||||
end
|
||||
|
||||
def test_update
|
||||
@wiki = Wiki.find(1)
|
||||
|
|
Loading…
Reference in New Issue