replace rspec's deprecated mock() with double()
avoid matching of common ruby and javascript code