Skip to content

Commit 93519a5

Browse files
authored
Update for changed namespace
1 parent fe2178f commit 93519a5

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

js/closure/openlocationcode_test.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
goog.module('openlocationcode_test');
2323
goog.setTestOnly('openlocationcode_test');
2424

25-
var openlocationcode = goog.require('google.openlocationcode');
25+
var OpenLocationCode = goog.require('openlocationcode.OpenLocationCode');
2626
var testSuite = goog.require('goog.testing.testSuite');
2727
goog.require('goog.testing.asserts');
2828

@@ -162,9 +162,9 @@ testSuite({
162162
for (var i = 0; i < tests.length; i++) {
163163
var td = tests[i];
164164
// Decode the code.
165-
var ca = openlocationcode.decode(td[0]);
165+
var ca = OpenLocationCode.decode(td[0]);
166166
// Encode the center coordinates.
167-
var code = openlocationcode.encode(td[1], td[2], ca.codeLength);
167+
var code = OpenLocationCode.encode(td[1], td[2], ca.codeLength);
168168
// Did we get the same code?
169169
assertEquals('Test ' + 1, td[0], code);
170170
// Check that the decode gave the correct coordinates.
@@ -250,9 +250,9 @@ testSuite({
250250
for (var i = 0; i < tests.length; i++) {
251251
var td = tests[i];
252252
// Shorten the code.
253-
var short = openlocationcode.shorten(td[0], td[1], td[2]);
253+
var short = OpenLocationCode.shorten(td[0], td[1], td[2]);
254254
assertEquals('Test ' + i, short, td[3]);
255-
var recovered = openlocationcode.recoverNearest(short, td[1], td[2]);
255+
var recovered = OpenLocationCode.recoverNearest(short, td[1], td[2]);
256256
assertEquals('Test ' + i, recovered, td[0]);
257257
}
258258
},
@@ -367,9 +367,9 @@ testSuite({
367367
];
368368
for (var i = 0; i < tests.length; i++) {
369369
var td = tests[i];
370-
assertEquals('Test ' + i, openlocationcode.isValid(td[0]), td[1]);
371-
assertEquals('Test ' + i, openlocationcode.isShort(td[0]), td[2]);
372-
assertEquals('Test ' + i, openlocationcode.isFull(td[0]), td[3]);
370+
assertEquals('Test ' + i, OpenLocationCode.isValid(td[0]), td[1]);
371+
assertEquals('Test ' + i, OpenLocationCode.isShort(td[0]), td[2]);
372+
assertEquals('Test ' + i, OpenLocationCode.isFull(td[0]), td[3]);
373373
}
374374
},
375375
});

0 commit comments

Comments
 (0)