Bug 1892041 - Part 2: Update test262. r=spidermonkey-reviewers,dminor
[gecko.git] / js / src / tests / test262 / built-ins / String / prototype / toLocaleUpperCase / S15.5.4.19_A1_T4.js
blob6afd8033f0754b40c125f2f5b92bd46185a36e79
1 // Copyright 2009 the Sputnik authors.  All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
4 /*---
5 info: String.prototype.toLocaleUpperCase()
6 es5id: 15.5.4.19_A1_T4
7 description: >
8     Call toLocaleUpperCase() function without arguments of string and
9     from empty string
10 ---*/
12 var __lowerCase = "".toLocaleUpperCase();
13 var __expected = "";
15 //////////////////////////////////////////////////////////////////////////////
16 //CHECK#1
17 if (__lowerCase.length !== __expected.length) {
18   throw new Test262Error('#1: __lowerCase = "".toLocaleUpperCase(); __expected = ""; __lowerCase.length === __expected.length. Actual: ' + __lowerCase.length);
21 //////////////////////////////////////////////////////////////////////////////
23 //////////////////////////////////////////////////////////////////////////////
24 //CHECK#2
25 if (__lowerCase.index !== __expected.index) {
26   throw new Test262Error('#2: __lowerCase = "".toLocaleUpperCase(); __expected = ""; __lowerCase.index === __expected.index. Actual: ' + __lowerCase.index);
29 //////////////////////////////////////////////////////////////////////////////
31 //////////////////////////////////////////////////////////////////////////////
32 //CHECK#3
33 if (__lowerCase.input !== __expected.input) {
34   throw new Test262Error('#3: __lowerCase = "".toLocaleUpperCase(); __expected = ""; __lowerCase.input === __expected.input. Actual: ' + __lowerCase.input);
37 //////////////////////////////////////////////////////////////////////////////
39 //////////////////////////////////////////////////////////////////////////////
40 //CHECK#4
41 if (__lowerCase[0] !== __expected[0]) {
42   throw new Test262Error('#4: __lowerCase = "".toLocaleUpperCase(); __lowerCase[0]===' + __expected[0] + '. Actual: ' + __lowerCase[0]);
45 //////////////////////////////////////////////////////////////////////////////
47 reportCompare(0, 0);