Refactoring of RSpec tests

Eliminate dublications