(#16081) Fixed problems with rspec tests