summaryrefslogtreecommitdiff
path: root/platform/darwin/test/MGLStyleValueTests.swift
diff options
context:
space:
mode:
authorJesse Bounds <jesse@rebounds.net>2017-02-16 19:46:00 -0800
committerJesse Bounds <jesse@rebounds.net>2017-03-03 09:10:31 -0800
commitd25e2c772daeb44f3933a0114f41c86b9679e8c1 (patch)
tree8363870624166056be3c6df48002ea1157ad1a4d /platform/darwin/test/MGLStyleValueTests.swift
parentf1e3c32f7ea9e5a1d80b8ddd136751ca131c3eb5 (diff)
downloadqtlocation-mapboxgl-d25e2c772daeb44f3933a0114f41c86b9679e8c1.tar.gz
[ios, macos] Rename MGLStyleConstantValue to MGLConstantStyleValue
Diffstat (limited to 'platform/darwin/test/MGLStyleValueTests.swift')
-rw-r--r--platform/darwin/test/MGLStyleValueTests.swift24
1 files changed, 12 insertions, 12 deletions
diff --git a/platform/darwin/test/MGLStyleValueTests.swift b/platform/darwin/test/MGLStyleValueTests.swift
index f965c31e40..784b2fbaf1 100644
--- a/platform/darwin/test/MGLStyleValueTests.swift
+++ b/platform/darwin/test/MGLStyleValueTests.swift
@@ -24,8 +24,8 @@ extension MGLStyleValueTests {
return
}
- if let actualConstant = actual as? MGLStyleConstantValue<MGLColor> {
- assertColorsEqualWithAccuracy(actualConstant.rawValue, (expected as! MGLStyleConstantValue<MGLColor>).rawValue)
+ if let actualConstant = actual as? MGLConstantStyleValue<MGLColor> {
+ assertColorsEqualWithAccuracy(actualConstant.rawValue, (expected as! MGLConstantStyleValue<MGLColor>).rawValue)
} else if let actualFunction = actual as? MGLStyleFunction<MGLColor>,
let expectedFunction = expected as? MGLStyleFunction<MGLColor> {
@@ -55,11 +55,11 @@ extension MGLStyleValueTests {
XCTFail("Expected stop value of type \(type(of: expectedValue)), but found \(type(of: actualValue)) instead.")
return
}
- if let actualValue = actualValue as? MGLStyleConstantValue<MGLColor>,
- let expectedValue = expectedValue as? MGLStyleConstantValue<MGLColor> {
+ if let actualValue = actualValue as? MGLConstantStyleValue<MGLColor>,
+ let expectedValue = expectedValue as? MGLConstantStyleValue<MGLColor> {
assertColorsEqualWithAccuracy(actualValue.rawValue, expectedValue.rawValue)
- } else if let actualValue = actualValue as? MGLStyleConstantValue<AnyObject>,
- let expectedValue = expectedValue as? MGLStyleConstantValue<AnyObject> {
+ } else if let actualValue = actualValue as? MGLConstantStyleValue<AnyObject>,
+ let expectedValue = expectedValue as? MGLConstantStyleValue<AnyObject> {
XCTAssertEqual(actualValue, expectedValue)
} else {
XCTFail("Unsupported stop value type \(type(of: actualValue)).")
@@ -90,16 +90,16 @@ extension MGLStyleValueTests {
let circleStyleLayer = MGLCircleStyleLayer(identifier: "circleLayer", source: shapeSource)
// Boolean
- symbolStyleLayer.iconAllowsOverlap = MGLStyleConstantValue(rawValue: true)
- XCTAssertEqual((symbolStyleLayer.iconAllowsOverlap as! MGLStyleConstantValue<NSNumber>).rawValue, true)
+ symbolStyleLayer.iconAllowsOverlap = MGLConstantStyleValue(rawValue: true)
+ XCTAssertEqual((symbolStyleLayer.iconAllowsOverlap as! MGLConstantStyleValue<NSNumber>).rawValue, true)
// Number
- symbolStyleLayer.iconHaloWidth = MGLStyleConstantValue(rawValue: 3)
- XCTAssertEqual((symbolStyleLayer.iconHaloWidth as! MGLStyleConstantValue<NSNumber>).rawValue, 3)
+ symbolStyleLayer.iconHaloWidth = MGLConstantStyleValue(rawValue: 3)
+ XCTAssertEqual((symbolStyleLayer.iconHaloWidth as! MGLConstantStyleValue<NSNumber>).rawValue, 3)
// String
- symbolStyleLayer.text = MGLStyleConstantValue(rawValue: "{name}")
- XCTAssertEqual((symbolStyleLayer.text as! MGLStyleConstantValue<NSString>).rawValue, "{name}")
+ symbolStyleLayer.text = MGLConstantStyleValue(rawValue: "{name}")
+ XCTAssertEqual((symbolStyleLayer.text as! MGLConstantStyleValue<NSString>).rawValue, "{name}")
var circleTranslationOne = CGVector(dx: 100, dy: 0)
let circleTranslationValueOne = NSValue(bytes: &circleTranslationOne, objCType: "{CGVector=dd}")