summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnand Thakker <github@anandthakker.net>2018-02-06 07:58:07 -0500
committerMinh Nguyễn <mxn@1ec5.org>2018-02-07 02:14:10 -0800
commited970d11cb9e3faa6542387be6e1be2754448121 (patch)
tree1af2a27e00d42425e466844da61bbcc7ac3b9bb6
parent0406566bbdbd856aa7c588a574e18da7fc304697 (diff)
downloadqtlocation-mapboxgl-ed970d11cb9e3faa6542387be6e1be2754448121.tar.gz
Fix incorrect NSExpressions in MGLHeatmapColorTests
-rw-r--r--platform/darwin/test/MGLHeatmapColorTests.mm6
1 files changed, 3 insertions, 3 deletions
diff --git a/platform/darwin/test/MGLHeatmapColorTests.mm b/platform/darwin/test/MGLHeatmapColorTests.mm
index 74045ea68e..8d44064d94 100644
--- a/platform/darwin/test/MGLHeatmapColorTests.mm
+++ b/platform/darwin/test/MGLHeatmapColorTests.mm
@@ -21,7 +21,7 @@
@"heatmap-color should be unset initially.");
NSExpression *defaultExpression = layer.heatmapColor;
- NSExpression *constantExpression = [NSExpression expressionWithFormat:@"red"];
+ NSExpression *constantExpression = [NSExpression expressionWithFormat:@"%@", [MGLColor redColor]];
layer.heatmapColor = constantExpression;
@@ -31,8 +31,8 @@
XCTAssertEqualObjects(layer.heatmapColor, constantExpression,
@"heatmapColor should round-trip constant value expressions.");
- constantExpression = [NSExpression expressionWithFormat:@"red"];
- NSExpression *constantExpression2 = [NSExpression expressionWithFormat:@"blue"];
+ constantExpression = [NSExpression expressionWithFormat:@"%@", [MGLColor redColor]];
+ NSExpression *constantExpression2 = [NSExpression expressionWithFormat:@"%@", [MGLColor blueColor]];
NSExpression *functionExpression = [NSExpression expressionWithFormat:@"FUNCTION($heatmapDensity, 'mgl_stepWithMinimum:stops:', %@, %@)", constantExpression, @{@12: constantExpression2}];
layer.heatmapColor = functionExpression;