4
5
6
7
8
9
10
11
12
|
# File 'lib/copyable/syntax_checking/syntax_checker.rb', line 4
def self.check!(model_class, declaration_block)
raise CopyableError.new("You must pass copyable a block") if declaration_block.nil?
declaration_checker = DeclarationChecker.new
declaration_checker.verify!(declaration_block)
column_checker = ColumnChecker.new(model_class)
column_checker.verify!(declaration_block)
association_checker = AssociationChecker.new(model_class)
association_checker.verify!(declaration_block)
end
|