Leo Le Leo Le - 5 months ago 24
Ruby Question

Cannot run rspec with filter tags

I have spec

RSpec.describe SearchFlight::Jet::SearchFlightRequest do
describe 'send search ticket request to Jetstar website', http_request: true do
context 'search ticket round trip successfully' do
# initialize
it 'return status 200' do
# my expects here ...
end
end
end
end


When I run rspec on my iterm, it couldn't run

bundle exec rspec -t ~http_request
zsh: no such user or named directory: http_request


Maybe it related to zsh command line (issue). I try to remove zsh from my iTerms 2 but it's not success. Any alternative shell for Rails dev ? Thanks

Answer

Try something like

rspec --tag "~http_request"