# frozen_string_literal: true require 'rails_helper' RSpec.describe Api::ProductsController, type: :controller do it { should route(:post, '/api/products').to(action: :create) } it do should route(:put, '/api/products/0439733420a4c5a3e8239bb1').to(action: :update, id: '0439733420a4c5a3e8239bb1') end it { should route(:get, '/api/products').to(action: :index) } it do should route(:get, '/api/products/0439733420a4c5a3e8239bb1').to(action: :show, id: '0439733420a4c5a3e8239bb1') end it do should route(:delete, '/api/products/0439733420a4c5a3e8239bb1').to(action: :destroy, id: '0439733420a4c5a3e8239bb1') end end