Sha256: f6e46f90c8235de77a16b16f198cc5d34aa910cfbe511577a2a8e843e009a52b
Contents?: true
Size: 443 Bytes
Versions: 9
Compression:
Stored size: 443 Bytes
Contents
module Gitlab module Styles module Rubocop # Module containing helper methods for writing migration cops. module MigrationHelpers # Returns true if the given node originated from the db/migrate directory. def in_migration?(node) dirname = File.dirname(node.location.expression.source_buffer.name) dirname.end_with?('db/migrate', 'db/post_migrate') end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems