lws 7.2.4 → 7.3.2
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 +4 -4
- data/lib/lws/apps/auth.rb +13 -14
- data/lib/lws/apps/corporate_website.rb +13 -13
- data/lib/lws/apps/digital_signage.rb +26 -17
- data/lib/lws/apps/generic.rb +29 -9
- data/lib/lws/apps/maps.rb +13 -13
- data/lib/lws/apps/presence.rb +23 -13
- data/lib/lws/apps/resource.rb +14 -14
- data/lib/lws/apps/ticket.rb +13 -13
- data/lib/lws/config.rb +24 -11
- data/lib/lws/errors.rb +8 -7
- data/lib/lws/middleware/http_logger.rb +8 -7
- data/lib/lws/middleware/json_logger.rb +8 -7
- data/lib/lws/middleware/json_parser.rb +8 -7
- data/lib/lws/middleware/request_headers.rb +8 -7
- data/lib/lws/middleware.rb +8 -7
- data/lib/lws/stubbing.rb +8 -7
- data/lib/lws/version.rb +9 -8
- data/lib/lws.rb +9 -9
- data/test/api_token_middleware_test.rb +8 -7
- data/test/auth_test.rb +8 -7
- data/test/caching_test.rb +8 -7
- data/test/config/full.yml +1 -0
- data/test/corporate_website_test.rb +8 -7
- data/test/digital_signage_test.rb +10 -9
- data/test/generic_test.rb +8 -7
- data/test/http_caching_test.rb +8 -7
- data/test/json_parser_test.rb +8 -7
- data/test/logger_test.rb +8 -7
- data/test/maps_test.rb +8 -7
- data/test/presence_test.rb +8 -7
- data/test/resource_test.rb +8 -7
- data/test/setup_test.rb +35 -9
- data/test/stubbing_test.rb +8 -7
- data/test/support/with_env.rb +8 -7
- data/test/test_helper.rb +8 -7
- data/test/ticket_test.rb +8 -7
- metadata +18 -18
data/lib/lws/middleware.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
module LWS
|
data/lib/lws/stubbing.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
module LWS
|
data/lib/lws/version.rb
CHANGED
@@ -1,18 +1,19 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
module LWS
|
13
14
|
|
14
15
|
# The LWS library version.
|
15
16
|
# @note The major and minor version parts match the LWS API version!
|
16
|
-
VERSION = "7.2
|
17
|
+
VERSION = "7.3.2".freeze
|
17
18
|
|
18
19
|
end
|
data/lib/lws.rb
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
10
|
-
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
11
11
|
|
12
12
|
require "faraday_middleware"
|
13
13
|
require "faraday/http_cache"
|
@@ -112,7 +112,7 @@ module LWS
|
|
112
112
|
# @param api_url [String] The endpoint URL of the API
|
113
113
|
# @return [Faraday::Connection] A Faraday connection that makes requests to the API
|
114
114
|
def self.setup_api(api_url)
|
115
|
-
api = Faraday.new(url: api_url) do |c|
|
115
|
+
api = Faraday.new(url: api_url, proxy: config.proxy) do |c|
|
116
116
|
# Request
|
117
117
|
if config.caching_object
|
118
118
|
c.use FaradayMiddleware::Caching, config.caching_object
|
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/auth_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/caching_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/config/full.yml
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
@@ -116,7 +117,7 @@ class TestDigitalSignageChannelTimeSchedule < MiniTest::Test
|
|
116
117
|
include LWS::DigitalSignage
|
117
118
|
|
118
119
|
def setup
|
119
|
-
@channel_time_schedule = Channel::TimeSchedule.
|
120
|
+
@channel_time_schedule = Channel::TimeSchedule.find(1)
|
120
121
|
end
|
121
122
|
|
122
123
|
def test_valid
|
@@ -137,7 +138,7 @@ class TestDigitalSignageChannelTimeScheduleDay < MiniTest::Test
|
|
137
138
|
include LWS::DigitalSignage
|
138
139
|
|
139
140
|
def setup
|
140
|
-
@channel_time_schedule = Channel::TimeSchedule.
|
141
|
+
@channel_time_schedule = Channel::TimeSchedule.find(1)
|
141
142
|
# Time schedule days only exist as child objects of a time schedule
|
142
143
|
@channel_time_schedule_day = @channel_time_schedule.days.first
|
143
144
|
end
|
data/test/generic_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/http_caching_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/json_parser_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/logger_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/maps_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/presence_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/resource_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/setup_test.rb
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
10
|
-
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
11
11
|
|
12
12
|
require "test_helper"
|
13
13
|
|
@@ -24,7 +24,7 @@ class TestSetup < MiniTest::Test
|
|
24
24
|
|
25
25
|
def test_cannot_leave_out_api_token
|
26
26
|
assert_raises do
|
27
|
-
LWS.setup {
|
27
|
+
LWS.setup {}
|
28
28
|
end
|
29
29
|
end
|
30
30
|
|
@@ -132,6 +132,7 @@ class TestSetup < MiniTest::Test
|
|
132
132
|
assert_equal(true, LWS.config.http_debug)
|
133
133
|
assert_equal(true, LWS.config.http_debug_headers)
|
134
134
|
assert_equal(true, LWS.config.json_debug)
|
135
|
+
assert_equal("http://user:password@proxyserver:8080", LWS.config.proxy)
|
135
136
|
|
136
137
|
with_env("LC_LWS_ENV" => "production") do
|
137
138
|
reconfigure do |config|
|
@@ -148,4 +149,29 @@ class TestSetup < MiniTest::Test
|
|
148
149
|
assert_equal(:development, LWS.config.environment)
|
149
150
|
end
|
150
151
|
|
152
|
+
def test_proxy
|
153
|
+
proxy_url = "http://user:password@proxyserver:8080"
|
154
|
+
reconfigure do |config|
|
155
|
+
config.proxy = proxy_url
|
156
|
+
end
|
157
|
+
|
158
|
+
assert_equal(proxy_url, LWS.config.proxy)
|
159
|
+
assert_equal("http://user:password@proxyserver:8080", LWS::Auth.api.proxy.uri.to_s)
|
160
|
+
assert_equal("user", LWS::Auth.api.proxy.user)
|
161
|
+
assert_equal("password", LWS::Auth.api.proxy.password)
|
162
|
+
|
163
|
+
proxy_options =
|
164
|
+
{ uri: Addressable::URI.parse("http://proxyserver:8080"),
|
165
|
+
user: "user",
|
166
|
+
password: "password" }
|
167
|
+
reconfigure do |config|
|
168
|
+
config.proxy = proxy_options
|
169
|
+
end
|
170
|
+
|
171
|
+
assert_equal(proxy_options, LWS.config.proxy)
|
172
|
+
assert_equal("http://proxyserver:8080", LWS::Auth.api.proxy.uri.to_s)
|
173
|
+
assert_equal("user", LWS::Auth.api.proxy.user)
|
174
|
+
assert_equal("password", LWS::Auth.api.proxy.password)
|
175
|
+
end
|
176
|
+
|
151
177
|
end
|
data/test/stubbing_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
data/test/support/with_env.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
class Minitest::Test
|
data/test/test_helper.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require 'simplecov'
|
data/test/ticket_test.rb
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
#
|
2
|
-
# Copyright © 2016–
|
2
|
+
# Copyright © 2016–2021 LeftClick Web Services B.V.
|
3
3
|
#
|
4
|
-
# This software is property of LeftClick B.V. and cannot be
|
5
|
-
# and/or modified without permission. The software or any
|
6
|
-
# cannot be used for any other purposes than the LeftClick
|
7
|
-
# only during a valid license subscription. For more
|
8
|
-
# contact LeftClick B.V. at:
|
9
|
-
#
|
4
|
+
# This software is property of LeftClick Web Services B.V. and cannot be
|
5
|
+
# redistributed and/or modified without permission. The software or any
|
6
|
+
# of its parts cannot be used for any other purposes than the LeftClick
|
7
|
+
# services and only during a valid license subscription. For more
|
8
|
+
# information, please contact LeftClick Web Services B.V. at:
|
9
|
+
# Schootense Dreef 20A, 5708 HZ Helmond, The Netherlands,
|
10
|
+
# info@leftclick.eu, +3185-4444-004.
|
10
11
|
|
11
12
|
|
12
13
|
require "test_helper"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lws
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.2
|
4
|
+
version: 7.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- LeftClick B.V.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-10-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday-http-cache
|
@@ -310,28 +310,28 @@ signing_key:
|
|
310
310
|
specification_version: 4
|
311
311
|
summary: LeftClick web services library for Ruby
|
312
312
|
test_files:
|
313
|
+
- test/presence_test.rb
|
313
314
|
- test/http_caching_test.rb
|
314
315
|
- test/generic_test.rb
|
315
|
-
- test/caching_test.rb
|
316
|
-
- test/api_token_middleware_test.rb
|
317
316
|
- test/corporate_website_test.rb
|
318
|
-
- test/ticket_test.rb
|
319
317
|
- test/stubbing_test.rb
|
320
|
-
- test/
|
321
|
-
- test/
|
318
|
+
- test/support/with_env.rb
|
319
|
+
- test/caching_test.rb
|
320
|
+
- test/maps_test.rb
|
321
|
+
- test/ticket_test.rb
|
322
|
+
- test/api_token_middleware_test.rb
|
323
|
+
- test/digital_signage_test.rb
|
324
|
+
- test/json_parser_test.rb
|
325
|
+
- test/logger_test.rb
|
326
|
+
- test/config/switch_env.yml
|
322
327
|
- test/config/full.yml
|
323
328
|
- test/config/empty.yml
|
324
|
-
- test/config/endpoints.yml
|
325
|
-
- test/config/switch_env.yml
|
326
329
|
- test/config/tokens.yml
|
327
|
-
- test/
|
328
|
-
- test/
|
329
|
-
- test/digital_signage_test.rb
|
330
|
-
- test/test_helper.rb
|
331
|
-
- test/maps_test.rb
|
332
|
-
- test/support/with_env.rb
|
333
|
-
- test/resource_test.rb
|
330
|
+
- test/config/invalid.yml
|
331
|
+
- test/config/endpoints.yml
|
334
332
|
- test/auth_test.rb
|
335
|
-
- test/
|
336
|
-
- test/fixtures/permissions.yml
|
333
|
+
- test/test_helper.rb
|
337
334
|
- test/fixtures/auth.yml
|
335
|
+
- test/fixtures/permissions.yml
|
336
|
+
- test/resource_test.rb
|
337
|
+
- test/setup_test.rb
|