diff --git a/Gemfile b/Gemfile index 85071c6eb..2d95468ba 100644 --- a/Gemfile +++ b/Gemfile @@ -4,22 +4,36 @@ source 'https://rubygems.org' git_source(:github) { |repo_name| "https://github.com/#{repo_name}" } -gem 'badge' -gem 'cocoapods' -gem 'danger' -gem 'danger-commit_lint' -gem 'fastlane' -gem 'fastlane-plugin-lizard' +gem 'danger', group: :danger_dependencies +gem 'fastlane', group: :fastlane_dependencies gem 'jazzy' gem 'json' -gem 'plist' -gem 'rubocop', '1.38' -gem 'rubocop-performance' -gem 'rubocop-require_tools' -gem 'sinatra' +gem 'rubocop', '1.38', group: :rubocop_dependencies +gem 'sinatra', group: :sinatra_dependencies gem 'slather' -gem 'xcode-install' -gem 'xctest_list' plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile') eval_gemfile(plugins_path) if File.exist?(plugins_path) + +group :fastlane_dependencies do + gem 'badge' + gem 'cocoapods' + gem 'fastlane-plugin-lizard' + gem 'plist' + gem 'xcode-install' + gem 'xctest_list' +end + +group :sinatra_dependencies do + gem 'puma' + gem 'rackup' +end + +group :rubocop_dependencies do + gem 'rubocop-performance' + gem 'rubocop-require_tools' +end + +group :danger_dependencies do + gem 'danger-commit_lint' +end diff --git a/Gemfile.lock b/Gemfile.lock index 858bd2324..2749c2d2c 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -288,6 +288,7 @@ GEM nap (1.1.0) naturally (2.2.1) netrc (0.11.0) + nio4r (2.7.0) no_proxy_fix (0.1.2) nokogiri (1.16.0) mini_portile2 (~> 2.8.2) @@ -307,6 +308,8 @@ GEM coderay (~> 1.1) method_source (~> 1.0) public_suffix (4.0.7) + puma (6.4.2) + nio4r (~> 2.0) racc (1.7.3) rack (3.0.8) rack-protection (4.0.0) @@ -314,6 +317,9 @@ GEM rack (>= 3.0.0, < 4) rack-session (2.0.0) rack (>= 3.0.0) + rackup (2.1.0) + rack (>= 3) + webrick (~> 1.8) rainbow (3.1.1) rake (13.1.0) rchardet (1.8.0) @@ -390,6 +396,7 @@ GEM concurrent-ruby (~> 1.0) uber (0.1.0) unicode-display_width (2.5.0) + webrick (1.8.1) word_wrap (1.0.0) xcinvoke (0.3.0) liferaft (~> 0.0.6) @@ -425,6 +432,8 @@ DEPENDENCIES jazzy json plist + puma + rackup rubocop (= 1.38) rubocop-performance rubocop-require_tools diff --git a/TestTools/Robots/Sinatra.swift b/TestTools/Robots/Sinatra.swift index 1ef97d5ba..e3049fd6d 100644 --- a/TestTools/Robots/Sinatra.swift +++ b/TestTools/Robots/Sinatra.swift @@ -27,6 +27,7 @@ public class Sinatra { private func invokeSinatra(url: URL, body: [String: Any] = [:]) { var request = URLRequest(url: url) request.httpMethod = "POST" + request.addValue("application/json", forHTTPHeaderField: "Content-Type") request.httpBody = try? JSONSerialization.data(withJSONObject: body, options: []) URLSession.shared.dataTask(with: request).resume() }