shopify_api_test.rb 418 B

123456789101112131415161718
  1. require 'test_helper'
  2. class ShopifyApiTest < Test::Unit::TestCase
  3. def setup
  4. @session_no_token = ShopifyAPI::Session.new("testshop.myshopify.com")
  5. @session = ShopifyAPI::Session.new("testshop.myshopify.com", "any-token")
  6. end
  7. def test_session_not_valid_without_token
  8. assert_not @session_no_token.valid?
  9. end
  10. def test_session_is_valid_with_any_token
  11. assert @session.valid?
  12. end
  13. end