Skip plugin test, if redmine_sudo is installed

This commit is contained in:
Alexander Meindl 2022-06-22 11:47:28 +02:00
parent e47c09d938
commit 081097ec4b
3 changed files with 7 additions and 3 deletions

View File

@ -10,9 +10,9 @@ gemspec
# (this is used to not create conflicts with other plugins)
if File.file? File.expand_path './.enable_dev', __dir__
group :development, :test do
gem 'awesome_print', require: 'ap'
gem 'better_errors'
gem 'binding_of_caller'
# gem 'awesome_print', require: 'ap'
# gem 'better_errors'
# gem 'binding_of_caller'
gem 'debug'
gem 'marginalia'
gem 'memory_profiler'

View File

@ -22,6 +22,8 @@ module Additionals
end
module InstanceMethods
private
def validate_issue_allowed
return unless issue_id && issue
# NOTE: do not use user time zone here, because issue do not use it

View File

@ -4,6 +4,8 @@ require File.expand_path '../../test_helper', __FILE__
class AdditionalsPluginTest < Additionals::TestCase
def test_known_plugin
skip 'Skip test, because redmine_sudo should not be installed for this test.' if Redmine::Plugin.installed? :redmine_sudo
assert_not AdditionalsPlugin.active_sudo?
end