active_fulfillment 3.2.10 → 3.2.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5a9b9b2acd1f20e8d2ada62d9bc3d0544dc51f72fcbb9bc473f9958efd6c0d7b
|
|
4
|
+
data.tar.gz: b9e205c36d36a4e7fabc9890d9e54572531e143df9fc89f1121e958b4267884f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0c231a91b35cdda7ba0395c3c5190b1401902b6b2ca6ec7266de08a25f231e507591057f4b1a3b551f84b67eeabd4b21139e6b023cdbfb5f179825bfb73a8bf8
|
|
7
|
+
data.tar.gz: f0bfa7d61333afb33f453587a609749035e6288519541e5beb76d0b4d5a86b209a4f10677410c7b528dca4ff816af01be285d07fa0d648f98dc933c535aa813b
|
data/CHANGELOG.md
CHANGED
|
@@ -68,7 +68,7 @@ module ActiveFulfillment
|
|
|
68
68
|
private
|
|
69
69
|
|
|
70
70
|
def request_uri(action, data)
|
|
71
|
-
url =
|
|
71
|
+
url = File.join(@callback_url, "#{action}.#{@format}?#{data.to_query}")
|
|
72
72
|
end
|
|
73
73
|
|
|
74
74
|
def send_app_request(action, headers, data)
|
|
@@ -35,6 +35,19 @@ class ShopifyAPITest < Minitest::Test
|
|
|
35
35
|
end
|
|
36
36
|
end
|
|
37
37
|
|
|
38
|
+
def test_request_uri_is_correct_when_callback_url_has_additional_element
|
|
39
|
+
Timecop.freeze do
|
|
40
|
+
service = build_service(callback_url: 'https://dotcom-prod.bluemercuryio.com/v1/dotcom')
|
|
41
|
+
timestamp = Time.now.utc.to_i
|
|
42
|
+
uri = service.send(:request_uri, 'fetch_stock', {sku: '123', timestamp: timestamp, shop: 'www.snowwowdevil.ca'})
|
|
43
|
+
assert_equal "https://dotcom-prod.bluemercuryio.com/v1/dotcom/fetch_stock.json?shop=www.snowwowdevil.ca&sku=123×tamp=#{timestamp}", uri.to_s
|
|
44
|
+
|
|
45
|
+
service = build_service(callback_url: 'http://supershopifyapptwin.com/shopify/')
|
|
46
|
+
uri = service.send(:request_uri, 'fetch_stock', {sku: '123', timestamp: timestamp, shop: 'www.snowwowdevil.ca'})
|
|
47
|
+
assert_equal "http://supershopifyapptwin.com/shopify/fetch_stock.json?shop=www.snowwowdevil.ca&sku=123×tamp=#{timestamp}", uri.to_s
|
|
48
|
+
end
|
|
49
|
+
end
|
|
50
|
+
|
|
38
51
|
def test_response_from_failed_stock_request
|
|
39
52
|
mock_app_request('fetch_stock', anything, nil)
|
|
40
53
|
response = @service.fetch_stock_levels()
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: active_fulfillment
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.2.
|
|
4
|
+
version: 3.2.11
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Cody Fauser
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2020-09-
|
|
12
|
+
date: 2020-09-14 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: activesupport
|