test/access/store_test.rb in access-2.0.48 vs test/access/store_test.rb in access-2.0.49

- old
+ new

@@ -1,17 +1,17 @@ require './test/test_helper' class StoreTest < Minitest::Test def get_first_store - VCR.use_cassette('store search') do + VCR.use_cassette('store/search_first') do @first_store = Access::Store.search(member_key: 'API_RUBY_GEM_TEST', per_page: 1).stores.first end end def test_stores_search - VCR.use_cassette('store search') do + VCR.use_cassette('store/search') do stores_response = Access::Store.search(member_key: 'API_RUBY_GEM_TEST', per_page: 1) assert stores_response.success first_store = stores_response.stores.first assert_kind_of Access::StoreResponse, stores_response assert_kind_of Access::Link, stores_response.links @@ -26,11 +26,11 @@ end end def test_stores_find get_first_store - VCR.use_cassette('store find') do + VCR.use_cassette('store/find') do stores_response = Access::Store.find(@first_store.store_key, member_key: 'API_RUBY_GEM_TEST') assert stores_response.success first_store = stores_response.stores.first # pp stores_response.inspect assert_kind_of Access::StoreResponse, stores_response @@ -39,20 +39,20 @@ assert_kind_of Access::Category, first_store.store_categories.first end end def test_national_stores_find - VCR.use_cassette('national stores') do + VCR.use_cassette('store/national_stores') do stores_response = Access::Store.national(per_page: 1, member_key: 'API_RUBY_GEM_TEST') assert stores_response.success first_store = stores_response.stores.first assert_kind_of Access::StoreResponse, stores_response assert_kind_of Access::Store, first_store end end def test_stores_fail_member_key - VCR.use_cassette('store search fail member key') do + VCR.use_cassette('store/search_fail_member_key') do stores_response = Access::Store.search(query: 'pizza') refute stores_response.success assert_kind_of Access::StoreResponse, stores_response assert_kind_of Access::Error, stores_response.error assert_equal 401, stores_response.error.status_code