diff --git a/.github/workflows/master-push.yml b/.github/workflows/master-push.yml index 1820bca2a0..fcf518d88f 100644 --- a/.github/workflows/master-push.yml +++ b/.github/workflows/master-push.yml @@ -6,8 +6,8 @@ on: - "master" - "release/**" env: - XCODE_VERSION: "['15.1', '15.2', '15.3']" - XCODE_TEST_VERSIONS: "['15.1', '15.2', '15.3']" + XCODE_VERSION: "['15.1', '15.2', '15.3', '15.4']" + XCODE_TEST_VERSIONS: "['15.1', '15.2', '15.3', '15.4']" PLATFORM: "['ios', 'osx', 'watchos', 'tvos', 'catalyst', 'visionos']" BUILD_PLATFORM: "['ios', 'iossimulator', 'osx', 'watchos', 'watchossimulator', 'tvos', 'tvossimulator', 'catalyst', 'visionos', 'visionossimulator']" DOC_VERSION: '15.3' diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index a37523e4c2..b279ad4bc1 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -1,7 +1,7 @@ name: Publish release on: workflow_dispatch env: - XCODE_VERSION: "['15.1', '15.2', '15.3']" + XCODE_VERSION: "['15.1', '15.2', '15.3', '15.4']" TEST_XCODE_VERSION: '15.3' jobs: prepare: diff --git a/CHANGELOG.md b/CHANGELOG.md index bfdc478508..c09702e157 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,7 @@ x.y.z Release notes (yyyy-MM-dd) ============================================================= ### Enhancements -* None. +* Update release packaging for Xcode 15.4. ### Fixed * ([#????](https://github.com/realm/realm-swift/issues/????), since v?.?.?) @@ -13,9 +13,9 @@ x.y.z Release notes (yyyy-MM-dd) ### Compatibility * Realm Studio: 15.0.0 or later. * APIs are backwards compatible with all previous releases in the 10.x.y series. -* Carthage release for Swift is built with Xcode 15.3.0. +* Carthage release for Swift is built with Xcode 15.4.0. * CocoaPods: 1.10 or later. -* Xcode: 15.1.0-15.3.0. +* Xcode: 15.1.0-15.4.0. ### Internal * Upgraded realm-core from ? to ? diff --git a/Realm/TestUtils/TestUtils.mm b/Realm/TestUtils/TestUtils.mm index c4ca7f3085..d4a5b92b97 100644 --- a/Realm/TestUtils/TestUtils.mm +++ b/Realm/TestUtils/TestUtils.mm @@ -166,30 +166,6 @@ bool RLMHasCachedRealmForPath(NSString *path) { return RLMGetAnyCachedRealmForPath(path.UTF8String); } -static std::string serialize(id obj) { - auto data = [NSJSONSerialization dataWithJSONObject:obj - options:0 - error:nil]; - return std::string(static_cast(data.bytes), data.length); -} - -static std::string fakeJWT() { - std::string unencoded_prefix = serialize(@{@"alg": @"HS256"}); - std::string unencoded_body = serialize(@{ - @"user_data": @{@"token": @"dummy token"}, - @"exp": @123, - @"iat": @456, - @"access": @[@"download", @"upload"] - }); - std::string encoded_prefix, encoded_body; - encoded_prefix.resize(realm::util::base64_encoded_size(unencoded_prefix.size())); - encoded_body.resize(realm::util::base64_encoded_size(unencoded_body.size())); - realm::util::base64_encode(unencoded_prefix, encoded_prefix); - realm::util::base64_encode(unencoded_body, encoded_body); - std::string suffix = "Et9HFtf9R3GEMA0IICOfFMVXY7kkTX1wr4qCyhIf58U"; - return encoded_prefix + "." + encoded_body + "." + suffix; -} - // A network transport which doesn't actually do anything @interface NoOpTransport : NSObject @end @@ -261,18 +237,6 @@ + (RLMRealmConfiguration *)fakeFlexibleSyncConfiguration { } @end -// Xcode 13 adds -[NSUUID compare:] so this warns about the category -// implementing a method which already exists, but we can't use just the -// built-in one yet. -#pragma clang diagnostic push -#pragma clang diagnostic ignored "-Wobjc-protocol-method-implementation" -@implementation NSUUID (RLMUUIDCompareTests) -- (NSComparisonResult)compare:(NSUUID *)other { - return [[self UUIDString] compare:other.UUIDString]; -} -@end -#pragma clang diagnostic pop - bool RLMThreadSanitizerEnabled() { #if __has_feature(thread_sanitizer) return true; diff --git a/Realm/TestUtils/include/TestUtils.h b/Realm/TestUtils/include/TestUtils.h index 55b2cfc053..5fddace785 100644 --- a/Realm/TestUtils/include/TestUtils.h +++ b/Realm/TestUtils/include/TestUtils.h @@ -21,21 +21,19 @@ #import +RLM_HEADER_AUDIT_BEGIN(nullability) + FOUNDATION_EXTERN void RLMAssertThrowsWithReasonMatchingSwift(XCTestCase *self, __attribute__((noescape)) dispatch_block_t block, NSString *regexString, - NSString *message, + NSString *_Nullable message, NSString *fileName, NSUInteger lineNumber); @interface RLMRealmConfiguration (TestUser) -+ (RLMRealmConfiguration *_Nonnull)fakeSyncConfiguration; -+ (RLMRealmConfiguration *_Nonnull)fakeFlexibleSyncConfiguration; -@end - -@interface NSUUID (RLMUUIDCompareTests) -- (NSComparisonResult)compare:(NSUUID *)other; ++ (RLMRealmConfiguration *)fakeSyncConfiguration; ++ (RLMRealmConfiguration *)fakeFlexibleSyncConfiguration; @end // It appears to be impossible to check this from Swift so we need a helper function @@ -44,3 +42,4 @@ FOUNDATION_EXTERN bool RLMThreadSanitizerEnabled(void); FOUNDATION_EXTERN bool RLMCanFork(void); FOUNDATION_EXTERN pid_t RLMFork(void); +RLM_HEADER_AUDIT_END(nullability) diff --git a/build.sh b/build.sh index 52b01c01e1..22c3ff4735 100755 --- a/build.sh +++ b/build.sh @@ -1343,9 +1343,9 @@ x.y.z Release notes (yyyy-MM-dd) ### Compatibility * Realm Studio: 15.0.0 or later. * APIs are backwards compatible with all previous releases in the 10.x.y series. -* Carthage release for Swift is built with Xcode 15.3.0. +* Carthage release for Swift is built with Xcode 15.4.0. * CocoaPods: 1.10 or later. -* Xcode: 15.1.0-15.3.0. +* Xcode: 15.1.0-15.4.0. ### Internal * Upgraded realm-core from ? to ? diff --git a/scripts/package_examples.rb b/scripts/package_examples.rb index 4f3c2d06be..d3341b2cbc 100755 --- a/scripts/package_examples.rb +++ b/scripts/package_examples.rb @@ -44,7 +44,7 @@ def replace_framework(example, framework, path) "examples/tvos/swift", ] -xcode_versions = %w(15.1 15.2 15.3) +xcode_versions = %w(15.1 15.2 15.3 15.4) # Remove reference to Realm.xcodeproj from all example workspaces. base_examples.each do |example| diff --git a/scripts/pr-ci-matrix.rb b/scripts/pr-ci-matrix.rb index 2690979912..b3beb155da 100755 --- a/scripts/pr-ci-matrix.rb +++ b/scripts/pr-ci-matrix.rb @@ -86,7 +86,7 @@ def action # because they don't care about Xcode versions, while some others are latest-only # because they're particularly slow to run. module Workflows - XCODE_VERSIONS = %w(15.1 15.2 15.3) + XCODE_VERSIONS = %w(15.1 15.2 15.3 15.4) all = ->(v) { true } latest_only = ->(v) { v == XCODE_VERSIONS.last }