Initial commit - fresh start

This commit is contained in:
Ubuntu
2025-10-27 04:04:54 +00:00
parent a659275fb6
commit 52ab5d1005
265 changed files with 188424 additions and 64 deletions

View File

@@ -0,0 +1,17 @@
require 'spec_helper'
describe 'API V2 Storefront Products Spec', type: :request do
let(:store) { @default_store }
let!(:products) { create_list(:product, 5, stores: [store]) }
describe 'products#index' do
context 'with no params' do
before { get '/api/v2/storefront/products' }
it 'returns all products' do
expect(json_response['data'].count).to eq store.products.available.count
expect(json_response['data'].first).to have_type('product')
end
end
end
end