Fix ruby code and update rubocop config
Merge branch 'master' into adjust_tests