Browse Source

Remove "require" deprecated by Zeitwerk

rails6
parent
commit
41f6433b58
41 changed files with 4 additions and 118 deletions
  1. +2
    -1
      app/jobs/ssl_sync_job.rb
  2. +2
    -1
      app/jobs/whois_sync_job.rb
  3. +0
    -2
      app/services/notifier.rb
  4. +0
    -2
      app/services/null_logger.rb
  5. +0
    -6
      app/services/ssl.rb
  6. +0
    -3
      app/services/ssl/parser.rb
  7. +0
    -3
      app/services/system_command.rb
  8. +0
    -6
      app/services/whois.rb
  9. +0
    -10
      app/services/whois/parser.rb
  10. +0
    -4
      app/services/whois/parser/afilias.rb
  11. +0
    -4
      app/services/whois/parser/afnic.rb
  12. +0
    -3
      app/services/whois/parser/base.rb
  13. +0
    -4
      app/services/whois/parser/cira.rb
  14. +0
    -2
      app/services/whois/parser/entry/blank.rb
  15. +0
    -2
      app/services/whois/parser/entry/field.rb
  16. +0
    -2
      app/services/whois/parser/entry/text.rb
  17. +0
    -4
      app/services/whois/parser/entry_builder.rb
  18. +0
    -4
      app/services/whois/parser/io.rb
  19. +0
    -4
      app/services/whois/parser/neustar.rb
  20. +0
    -4
      app/services/whois/parser/sonic.rb
  21. +0
    -4
      app/services/whois/parser/verisign.rb
  22. +0
    -2
      lib/tasks/checks.rake
  23. +0
    -2
      lib/tasks/notifications.rake
  24. +0
    -1
      test/helpers/domain_helper_test.rb
  25. +0
    -2
      test/services/check_logger_test.rb
  26. +0
    -1
      test/services/notifier/resolver_test.rb
  27. +0
    -1
      test/services/notifier_test.rb
  28. +0
    -2
      test/services/ssl/parser_test.rb
  29. +0
    -2
      test/services/ssl_test.rb
  30. +0
    -1
      test/services/system_command_test.rb
  31. +0
    -3
      test/services/whois/parser/afilias_test.rb
  32. +0
    -3
      test/services/whois/parser/afnic_test.rb
  33. +0
    -3
      test/services/whois/parser/cira_test.rb
  34. +0
    -3
      test/services/whois/parser/io_test.rb
  35. +0
    -3
      test/services/whois/parser/neustar_test.rb
  36. +0
    -3
      test/services/whois/parser/sonic_test.rb
  37. +0
    -3
      test/services/whois/parser/verisign_test.rb
  38. +0
    -2
      test/services/whois/parser_test.rb
  39. +0
    -2
      test/services/whois_test.rb
  40. +0
    -2
      test/test_helper.rb
  41. +0
    -2
      test/test_mocks_helper.rb

+ 2
- 1
app/jobs/ssl_sync_job.rb View File

@@ -1,4 +1,5 @@
# require "ssl/errors"
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

class SSLSyncJob < ApplicationJob
queue_as :default


+ 2
- 1
app/jobs/whois_sync_job.rb View File

@@ -1,4 +1,5 @@
# require "whois/errors"
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

class WhoisSyncJob < ApplicationJob
queue_as :default


+ 0
- 2
app/services/notifier.rb View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "notifier/processor"

module Notifier
class << self
def process_all(configuration = nil)


+ 0
- 2
app/services/null_logger.rb View File

@@ -1,6 +1,4 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "naught"

NullLogger = Naught.build

+ 0
- 6
app/services/ssl.rb View File

@@ -1,12 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"
# require "system_command"
# require_relative "ssl/parser"
# require_relative "ssl/response"
# require_relative "ssl/errors"

module SSL
class Error < StandardError; end



+ 0
- 3
app/services/ssl/parser.rb View File

@@ -1,9 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"
# require "ssl/errors"

module SSL
class Parser
DATE_REGEX = /will expire on (.+)\./


+ 0
- 3
app/services/system_command.rb View File

@@ -1,9 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "open4"
# require "null_logger"

class SystemCommand
Result = Struct.new(:command, :exit_status, :stdout, :stderr)
class NotAllowedError < StandardError; end


+ 0
- 6
app/services/whois.rb View File

@@ -1,12 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"
# require "domain_helper"
# require "system_command"
# require_relative "whois/parser"
# require_relative "whois/response"
# require_relative "whois/errors"

module Whois
class Error < StandardError; end


+ 0
- 10
app/services/whois/parser.rb View File

@@ -1,16 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"
# require "whois/errors"
# require "whois/parser/afilias"
# require "whois/parser/afnic"
# require "whois/parser/cira"
# require "whois/parser/io"
# require "whois/parser/neustar"
# require "whois/parser/sonic"
# require "whois/parser/verisign"

module Whois
module Parser
PARSERS = [


+ 0
- 4
app/services/whois/parser/afilias.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class Afilias < Base


+ 0
- 4
app/services/whois/parser/afnic.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class AFNIC < Base


+ 0
- 3
app/services/whois/parser/base.rb View File

@@ -1,10 +1,7 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"
require_relative "../response"
# require_relative "../errors"
# require_relative "entry_builder"

module Whois
module Parser


+ 0
- 4
app/services/whois/parser/cira.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class CIRA < Base


+ 0
- 2
app/services/whois/parser/entry/blank.rb View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require_relative "base"

module Whois
module Parser
module Entry


+ 0
- 2
app/services/whois/parser/entry/field.rb View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require_relative "base"

module Whois
module Parser
module Entry


+ 0
- 2
app/services/whois/parser/entry/text.rb View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require_relative "base"

module Whois
module Parser
module Entry


+ 0
- 4
app/services/whois/parser/entry_builder.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require_relative "entry/blank"
# require_relative "entry/field"
# require_relative "entry/text"

module Whois
module Parser
class EntryBuilder


+ 0
- 4
app/services/whois/parser/io.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class IO < Base


+ 0
- 4
app/services/whois/parser/neustar.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class Neustar < Base


+ 0
- 4
app/services/whois/parser/sonic.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class Sonic < Base


+ 0
- 4
app/services/whois/parser/verisign.rb View File

@@ -1,10 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "domain_helper"
# require "whois/errors"
# require_relative "base"

module Whois
module Parser
class Verisign < Base


+ 0
- 2
lib/tasks/checks.rake View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "null_logger"

namespace :checks do
namespace :sync_dates do
task all: [:domain, :ssl]


+ 0
- 2
lib/tasks/notifications.rake View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "services/notifier"

namespace :notifications do
desc "Send all notifications after checks have been performend"
task send_all: :environment do


+ 0
- 1
test/helpers/domain_helper_test.rb View File

@@ -2,7 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "domain_helper"

class DomainHelperTest < ActiveSupport::TestCase
include DomainHelper


+ 0
- 2
test/services/check_logger_test.rb View File

@@ -2,8 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "check_logger"
# require "system_command"

class CheckLoggerTest < ActiveSupport::TestCase
setup do


+ 0
- 1
test/services/notifier/resolver_test.rb View File

@@ -2,7 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "notifier/resolver"

# rubocop:disable Metrics/LineLength
module Notifier


+ 0
- 1
test/services/notifier_test.rb View File

@@ -2,7 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "notifier"

class NotifierTest < ActiveSupport::TestCase
test "#process_all process expirable & failures notifications" do


+ 0
- 2
test/services/ssl/parser_test.rb View File

@@ -2,8 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "ssl/parser"
# require "ssl/errors"

module SSL
class ParserTest < ActiveSupport::TestCase


+ 0
- 2
test/services/ssl_test.rb View File

@@ -2,8 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "ssl"
# require "system_command"

module SSL
class ServiceTest < ActiveSupport::TestCase


+ 0
- 1
test/services/system_command_test.rb View File

@@ -2,7 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "system_command"

class SystemCommandTest < ActiveSupport::TestCase
test "should execute and log a command" do


+ 0
- 3
test/services/whois/parser/afilias_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/afilias"
# require "whois/response"
# require "whois/errors"

module Whois
class AfiliasTest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/afnic_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/afnic"
# require "whois/response"
# require "whois/errors"

module Whois
class AFNICTest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/cira_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/cira"
# require "whois/response"
# require "whois/errors"

module Whois
class CIRATest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/io_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/io"
# require "whois/response"
# require "whois/errors"

module Whois
class IOTest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/neustar_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/neustar"
# require "whois/response"
# require "whois/errors"

module Whois
class NeustarTest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/sonic_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/sonic"
# require "whois/response"
# require "whois/errors"

module Whois
class SonicTest < ActiveSupport::TestCase


+ 0
- 3
test/services/whois/parser/verisign_test.rb View File

@@ -2,9 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser/verisign"
# require "whois/response"
# require "whois/errors"

module Whois
class VerisignTest < ActiveSupport::TestCase


+ 0
- 2
test/services/whois/parser_test.rb View File

@@ -2,8 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois/parser"
# require "whois/errors"

module Whois
class ParserTest < ActiveSupport::TestCase


+ 0
- 2
test/services/whois_test.rb View File

@@ -2,8 +2,6 @@
# License: GNU AGPL-3+ (see full text in LICENSE file)

require "test_helper"
# require "whois"
# require "system_command"

module Whois
class ServiceTest < ActiveSupport::TestCase


+ 0
- 2
test/test_helper.rb View File

@@ -40,8 +40,6 @@ class ActiveSupport::TestCase
end

# Disable Open4 real system calls
# require "open4"
# require "errors"
module Open4
def popen4(*)
fail SystemCommand::NotAllowedError,


+ 0
- 2
test/test_mocks_helper.rb View File

@@ -1,8 +1,6 @@
# Copyright (C) 2018 Colin Darie <colin@darie.eu>, 2018 Evolix <info@evolix.fr>
# License: GNU AGPL-3+ (see full text in LICENSE file)

# require "system_command"

module TestMocksHelper
# rubocop:disable Metrics/MethodLength
def mock_system_command(program, args, exit_status: 0, stdout: "", stderr: "")


Loading…
Cancel
Save