From 6d75f96cb2061015a323e14d6585d31272b0a6d3 Mon Sep 17 00:00:00 2001 From: gumob Date: Sat, 24 Aug 2024 15:48:02 +0900 Subject: [PATCH 1/4] ci(fastlane/Fastfile): Update slather configuration for all test lanes and Carthage build lane to disable report opening and set output directory to fastlane/reports * Disable report opening by setting open\_report to false in all test lanes and Carthage build lane. * Set output directory to ./fastlane/reports for all test lanes and Carthage build lane. This change improves the organization of test reports and simplifies the fastlane configuration. --- fastlane/Fastfile | 80 ++++++++++++++++++++++++++++------------------- 1 file changed, 47 insertions(+), 33 deletions(-) diff --git a/fastlane/Fastfile b/fastlane/Fastfile index c9c1341..cada9f2 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -118,16 +118,16 @@ lane :test_all do # devices: ["iPhone SE (3rd generation)"], # clean: true, code_coverage: true, - open_report: true, + open_report: false, output_files: "report-ios.html,report-ios.junit", ) - # slather( - # scheme: scheme_iOS, - # proj: default_xcodeproj, - # output_directory: "./reports/iOS", - # html: true, - # show: true - # ) + slather( + scheme: scheme_iOS, + proj: default_xcodeproj, + output_directory: "./fastlane/reports/iOS", + html: true, + show: false + ) desc "Run macOS Tests" run_tests( @@ -135,16 +135,16 @@ lane :test_all do destination: "platform=macOS", # clean: true, code_coverage: true, - open_report: true, + open_report: false, output_files: "report-macos.html,report-macos.junit", ) - # slather( - # scheme: scheme_macOS, - # proj: default_xcodeproj, - # output_directory: "./reports/macOS", - # html: true, - # show: true - # ) + slather( + scheme: scheme_macOS, + proj: default_xcodeproj, + output_directory: "./fastlane/reports/macOS", + html: true, + show: false + ) desc "Run tvOS Tests" run_tests( @@ -152,16 +152,16 @@ lane :test_all do destination: "platform=tvOS Simulator,name=Apple TV 4K (3rd generation)", # clean: true, code_coverage: true, - open_report: true, + open_report: false, output_files: "report-tvos.html,report-tvos.junit", ) - # slather( - # scheme: scheme_tvOS, - # proj: default_xcodeproj, - # output_directory: "./reports/tvOS", - # html: true, - # show: true - # ) + slather( + scheme: scheme_tvOS, + proj: default_xcodeproj, + output_directory: "./fastlane/reports/tvOS", + html: true, + show: false + ) desc "Run watchOS Tests" run_tests( @@ -169,9 +169,16 @@ lane :test_all do destination: "platform=watchOS Simulator,name=Apple Watch Series 9 (45mm)", # clean: true, code_coverage: true, - open_report: true, + open_report: false, output_files: "report-watchos.html,report-watchos.junit", ) + slather( + scheme: scheme_watchOS, + proj: default_xcodeproj, + output_directory: "./fastlane/reports/watchOS", + html: true, + show: false + ) desc "Run visionOS Tests" run_tests( @@ -179,9 +186,16 @@ lane :test_all do destination: "platform=visionOS Simulator,name=Apple Vision Pro", # clean: true, code_coverage: true, - open_report: true, + open_report: false, output_files: "report-visionos.html,report-visionos.junit", ) + slather( + scheme: scheme_visionOS, + proj: default_xcodeproj, + output_directory: "./fastlane/reports/visionOS", + html: true, + show: false + ) end @@ -227,13 +241,13 @@ lane :build_carthage do |options| use_xcframeworks: true, no_skip_current: true ) - carthage( - command: "build", - verbose: false, - platform: "visionOS", - use_xcframeworks: true, - no_skip_current: true - ) + # carthage( + # command: "build", + # verbose: false, + # platform: "visionOS", + # use_xcframeworks: true, + # no_skip_current: true + # ) end desc "Lint Cocoapods" From c59557ad9a86f8953466bc0078c447c16f649186 Mon Sep 17 00:00:00 2001 From: gumob Date: Sat, 24 Aug 2024 15:49:43 +0900 Subject: [PATCH 2/4] chore: Add `fastlane/reports` to .gitignore (avoid committing test reports) Remove unused `.python-version` from .gitignore (use only `.python-version`) --- .gitignore | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index e150406..372b7f1 100644 --- a/.gitignore +++ b/.gitignore @@ -66,6 +66,7 @@ fastlane/report.xml fastlane/Preview.html fastlane/screenshots/**/*.png fastlane/test_output +fastlane/reports # Direnv .envrc @@ -75,4 +76,4 @@ fastlane/test_output .ruby-version # Python -.python-version +.python-version \ No newline at end of file From 9846e1d593c9209aa3095b12d38940e6492461db Mon Sep 17 00:00:00 2001 From: gumob Date: Sat, 24 Aug 2024 15:50:18 +0900 Subject: [PATCH 3/4] chore: Remove unused `.python-version` and `.ruby-version` from .gitignore --- .gitignore | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 372b7f1..a6321a4 100644 --- a/.gitignore +++ b/.gitignore @@ -72,8 +72,4 @@ fastlane/reports .envrc # Ruby -.bundle -.ruby-version - -# Python -.python-version \ No newline at end of file +.bundle \ No newline at end of file From 83834a2b0ccff64b927014807d23cabd8dcb59a6 Mon Sep 17 00:00:00 2001 From: gumob Date: Sat, 24 Aug 2024 17:18:49 +0900 Subject: [PATCH 4/4] refactor(Source/Extensions.swift, Source/Punycode.swift): replace 'Punycode' with 'Puny' to resolve namespace conflicts. public class 'Punycode.Punycode' shadows module 'Punycode', which may cause failures when importing 'Punycode' or its clients in some configurations; please rename either the class 'Punycode.Punycode' or the module 'Punycode', or see https://github.com/apple/swift/issues/56573 for workarounds --- Source/Extensions.swift | 8 ++++---- Source/Punycode.swift | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Source/Extensions.swift b/Source/Extensions.swift index 83bd282..ca340fa 100644 --- a/Source/Extensions.swift +++ b/Source/Extensions.swift @@ -11,28 +11,28 @@ public extension Substring { /// /// - Returns: Punycode encoded string or nil if the string can't be encoded var punycodeEncoded: String? { - return Punycode().encodePunycode(self) + return Puny().encodePunycode(self) } /// Returns new string decoded from punycode representation (RFC 3492) /// /// - Returns: Original string or nil if the string doesn't contain correct encoding var punycodeDecoded: String? { - return Punycode().decodePunycode(self) + return Puny().decodePunycode(self) } /// Returns new string containing IDNA-encoded hostname /// /// - Returns: IDNA encoded hostname or nil if the string can't be encoded var idnaEncoded: String? { - return Punycode().encodeIDNA(self) + return Puny().encodeIDNA(self) } /// Returns new string containing hostname decoded from IDNA representation /// /// - Returns: Original hostname or nil if the string doesn't contain correct encoding var idnaDecoded: String? { - return Punycode().decodedIDNA(self) + return Puny().decodedIDNA(self) } } diff --git a/Source/Punycode.swift b/Source/Punycode.swift index a22d6c5..b0257cd 100755 --- a/Source/Punycode.swift +++ b/Source/Punycode.swift @@ -10,7 +10,7 @@ import Foundation /// the class 'Punycode.Punycode' or the module 'Punycode', or see /// https://github.com/apple/swift/issues/56573 for workarounds -public class Punycode { +public class Puny { /// Punycode RFC 3492 /// See https://www.ietf.org/rfc/rfc3492.txt for standard details