For example here :
before_filter is deprecated syntax in rails 5. Therefore this should be replaced with before_action.
Assuming we want to run suite for previous rails versions (which I think we do) - do you have any good idea how to handle these differences?
In this specific case we can add one condition :
if Rails::VERSION < 5 before_filter else before_action end
But assuming we have lot of those specific conditions, maybe better solution would be to have these separated in subfolders.