diff --git a/app/views/contracts/index.html.erb b/app/views/contracts/index.html.erb
new file mode 100644
index 0000000..5418338
--- /dev/null
+++ b/app/views/contracts/index.html.erb
@@ -0,0 +1 @@
+Yay!
diff --git a/init.rb b/init.rb
index 531aee5..6f21f05 100644
--- a/init.rb
+++ b/init.rb
@@ -12,8 +12,14 @@ Redmine::Plugin.register :redmine_contracts do
requires_redmine_plugin :redmine_rate, :version_or_higher => '0.1.0'
project_module :contracts do
- permission :manage_budget, {}, :require => :member
+ permission :manage_budget, {:contracts => [:index] }, :public => true
end
+
+ menu(:project_menu,
+ :contracts,
+ {:controller => 'contracts', :action => 'index'},
+ :caption => :text_contracts,
+ :param => :project_id)
end
require 'dispatcher'
diff --git a/test/integration/contracts_list_test.rb b/test/integration/contracts_list_test.rb
new file mode 100644
index 0000000..abff216
--- /dev/null
+++ b/test/integration/contracts_list_test.rb
@@ -0,0 +1,17 @@
+require 'test_helper'
+
+class ContractsListTest < ActionController::IntegrationTest
+ def setup
+ @project = Project.generate!
+ @contract = Contract.generate!(:project => @project)
+ end
+
+ should "allow any user to list the contracts on a project" do
+ visit_project(@project)
+ click_link "Contracts"
+
+ assert_response :success
+ assert_template 'contracts/index'
+ end
+
+end