From 4dbff0ff55b095119db9a343b02c515d18ad7e57 Mon Sep 17 00:00:00 2001 From: Julian Rex Date: Mon, 30 Mar 2020 16:27:05 -0400 Subject: [PATCH] Fix compilation errors when compiling tests in release. (#245) --- platform/darwin/test/MGLTestAssertionHandler.m | 8 ++++---- .../Annotation Tests/MGLAnnotationViewIntegrationTests.mm | 2 +- .../ios/Integration Tests/MGLMapViewPendingBlockTests.m | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/platform/darwin/test/MGLTestAssertionHandler.m b/platform/darwin/test/MGLTestAssertionHandler.m index 4b504427b..2112387e3 100644 --- a/platform/darwin/test/MGLTestAssertionHandler.m +++ b/platform/darwin/test/MGLTestAssertionHandler.m @@ -35,9 +35,9 @@ ); } else { - NSLog(@"Assertion Failure: %@:%lu: %@ - %@", + NSLog(@"Assertion Failure: %@:%ld: %@ - %@", fileName, - line, + (long)line, condition, description); } @@ -66,9 +66,9 @@ description); } else { - NSLog(@"Assertion Failure: %@:%lu: %@ - %@", + NSLog(@"Assertion Failure: %@:%ld: %@ - %@", fileName, - line, + (long)line, condition, description); } diff --git a/platform/ios/Integration Tests/Annotation Tests/MGLAnnotationViewIntegrationTests.mm b/platform/ios/Integration Tests/Annotation Tests/MGLAnnotationViewIntegrationTests.mm index 1d0b0f622..381a13664 100644 --- a/platform/ios/Integration Tests/Annotation Tests/MGLAnnotationViewIntegrationTests.mm +++ b/platform/ios/Integration Tests/Annotation Tests/MGLAnnotationViewIntegrationTests.mm @@ -367,7 +367,7 @@ static const CGPoint kAnnotationRelativeScale = { 0.05f, 0.125f }; // Coord showsCallout impl margins? moveIntoView expectMapToPan calloutOnScreen { {offset, 0.5f}, YES, YES, YES, YES, YES }, - { {1.0 - offset, 0.5f}, YES, YES, YES, YES, YES }, + { {(CGFloat)(1.0 - offset), 0.5f}, YES, YES, YES, YES, YES }, PAN_TEST_TERMINATOR }; diff --git a/platform/ios/Integration Tests/MGLMapViewPendingBlockTests.m b/platform/ios/Integration Tests/MGLMapViewPendingBlockTests.m index c7925d789..2f3fdcc38 100644 --- a/platform/ios/Integration Tests/MGLMapViewPendingBlockTests.m +++ b/platform/ios/Integration Tests/MGLMapViewPendingBlockTests.m @@ -328,7 +328,7 @@ // Observes changes to pendingCompletionBlocks (including additions) self.observation = ^(NSDictionary *change){ - NSLog(@"change = %@ count = %lu", change, myself.mapView.pendingCompletionBlocks.count); + NSLog(@"change = %@ count = %lu", change, (unsigned long)myself.mapView.pendingCompletionBlocks.count); NSArray *value = change[NSKeyValueChangeNewKey];