Skip to content

Commit

Permalink
built-ins/Date/*: make all indentation consistent (depth & character) (
Browse files Browse the repository at this point in the history
  • Loading branch information
rwaldron authored and leobalter committed Feb 15, 2018
1 parent 6c50d46 commit b59d956
Show file tree
Hide file tree
Showing 391 changed files with 1,011 additions and 932 deletions.
10 changes: 5 additions & 5 deletions test/built-ins/Date/15.9.1.15-1.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ description: >
absent
---*/

var result = false;
var expectedDateTimeStr = "1970-01-01T00:00:00.000Z";
var dateObj = new Date("1970");
var dateStr = dateObj.toISOString();
result = dateStr === expectedDateTimeStr;
var result = false;
var expectedDateTimeStr = "1970-01-01T00:00:00.000Z";
var dateObj = new Date("1970");
var dateStr = dateObj.toISOString();
result = dateStr === expectedDateTimeStr;

assert(result, 'result !== true');
56 changes: 28 additions & 28 deletions test/built-ins/Date/S15.9.2.1_A1.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,71 +11,71 @@ description: Checking type of returned value
---*/

//CHECK#1
if( typeof Date() !== "string" ) {
$ERROR('#1: typeof Date() should be "string", actual is '+(typeof Date()));
if (typeof Date() !== "string") {
$ERROR('#1: typeof Date() should be "string", actual is ' + (typeof Date()));
}

//CHECK#2
if( typeof Date(1) !== "string" ) {
$ERROR('#2: typeof Date(1) should be "string", actual is '+(typeof Date(1)));
if (typeof Date(1) !== "string") {
$ERROR('#2: typeof Date(1) should be "string", actual is ' + (typeof Date(1)));
}

//CHECK#3
if( typeof Date(1970, 1) !== "string" ) {
$ERROR('#3: typeof Date(1970, 1) should be "string", actual is '+(typeof Date(1970, 1)));
if (typeof Date(1970, 1) !== "string") {
$ERROR('#3: typeof Date(1970, 1) should be "string", actual is ' + (typeof Date(1970, 1)));
}

//CHECK#4
if( typeof Date(1970, 1, 1) !== "string" ) {
$ERROR('#4: typeof Date(1970, 1, 1) should be "string", actual is '+(typeof Date(1970, 1, 1)));
if (typeof Date(1970, 1, 1) !== "string") {
$ERROR('#4: typeof Date(1970, 1, 1) should be "string", actual is ' + (typeof Date(1970, 1, 1)));
}

//CHECK#5
if( typeof Date(1970, 1, 1, 1) !== "string" ) {
$ERROR('#5: typeof Date(1970, 1, 1, 1) should be "string", actual is '+(typeof Date(1970, 1, 1, 1)));
if (typeof Date(1970, 1, 1, 1) !== "string") {
$ERROR('#5: typeof Date(1970, 1, 1, 1) should be "string", actual is ' + (typeof Date(1970, 1, 1, 1)));
}

//CHECK#6
if( typeof Date(1970, 1, 1, 1) !== "string" ) {
$ERROR('#7: typeof Date(1970, 1, 1, 1) should be "string", actual is '+(typeof Date(1970, 1, 1, 1)));
if (typeof Date(1970, 1, 1, 1) !== "string") {
$ERROR('#7: typeof Date(1970, 1, 1, 1) should be "string", actual is ' + (typeof Date(1970, 1, 1, 1)));
}

//CHECK#8
if( typeof Date(1970, 1, 1, 1, 0) !== "string" ) {
$ERROR('#8: typeof Date(1970, 1, 1, 1, 0) should be "string", actual is '+(typeof Date(1970, 1, 1, 1, 0)));
if (typeof Date(1970, 1, 1, 1, 0) !== "string") {
$ERROR('#8: typeof Date(1970, 1, 1, 1, 0) should be "string", actual is ' + (typeof Date(1970, 1, 1, 1, 0)));
}

//CHECK#9
if( typeof Date(1970, 1, 1, 1, 0, 0) !== "string" ) {
$ERROR('#9: typeof Date(1970, 1, 1, 1, 0, 0) should be "string", actual is '+(typeof Date(1970, 1, 1, 1, 0, 0)));
if (typeof Date(1970, 1, 1, 1, 0, 0) !== "string") {
$ERROR('#9: typeof Date(1970, 1, 1, 1, 0, 0) should be "string", actual is ' + (typeof Date(1970, 1, 1, 1, 0, 0)));
}

//CHECK#10
if( typeof Date(1970, 1, 1, 1, 0, 0, 0) !== "string" ) {
$ERROR('#10: typeof Date(1970, 1, 1, 1, 0, 0, 0) should be "string", actual is '+(typeof Date(1970, 1, 1, 1, 0, 0, 0)));
if (typeof Date(1970, 1, 1, 1, 0, 0, 0) !== "string") {
$ERROR('#10: typeof Date(1970, 1, 1, 1, 0, 0, 0) should be "string", actual is ' + (typeof Date(1970, 1, 1, 1, 0, 0, 0)));
}

//CHECK#11
if( typeof Date(Number.NaN) !== "string" ) {
$ERROR('#11: typeof Date(Number.NaN) should be "string", actual is '+(typeof Date(Number.NaN)));
if (typeof Date(Number.NaN) !== "string") {
$ERROR('#11: typeof Date(Number.NaN) should be "string", actual is ' + (typeof Date(Number.NaN)));
}

//CHECK#12
if( typeof Date(Number.POSITIVE_INFINITY) !== "string" ) {
$ERROR('#12: typeof Date(Number.POSITIVE_INFINITY) should be "string", actual is '+(typeof Date(Number.POSITIVE_INFINITY)));
if (typeof Date(Number.POSITIVE_INFINITY) !== "string") {
$ERROR('#12: typeof Date(Number.POSITIVE_INFINITY) should be "string", actual is ' + (typeof Date(Number.POSITIVE_INFINITY)));
}

//CHECK#13
if( typeof Date(Number.NEGATIVE_INFINITY) !== "string" ) {
$ERROR('#13: typeof Date(Number.NEGATIVE_INFINITY) should be "string", actual is '+(typeof Date(Number.NEGATIVE_INFINITY)));
if (typeof Date(Number.NEGATIVE_INFINITY) !== "string") {
$ERROR('#13: typeof Date(Number.NEGATIVE_INFINITY) should be "string", actual is ' + (typeof Date(Number.NEGATIVE_INFINITY)));
}

//CHECK#14
if( typeof Date(undefined) !== "string" ) {
$ERROR('#14: typeof Date(undefined) should be "string", actual is '+(typeof Date(undefined)));
if (typeof Date(undefined) !== "string") {
$ERROR('#14: typeof Date(undefined) should be "string", actual is ' + (typeof Date(undefined)));
}

//CHECK#15
if( typeof Date(null) !== "string" ) {
$ERROR('#15: typeof Date(null) should be "string", actual is '+(typeof Date(null)));
if (typeof Date(null) !== "string") {
$ERROR('#15: typeof Date(null) should be "string", actual is ' + (typeof Date(null)));
}
28 changes: 14 additions & 14 deletions test/built-ins/Date/S15.9.2.1_A2.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,71 +22,71 @@ function isEqual(d1, d2) {
}

//CHECK#1
if( !isEqual(Date(), (new Date()).toString()) ) {
if (!isEqual(Date(), (new Date()).toString())) {
$ERROR('#1: Date() is equal to (new Date()).toString()');
}

//CHECK#2
if( !isEqual(Date(1), (new Date()).toString()) ) {
if (!isEqual(Date(1), (new Date()).toString())) {
$ERROR('#2: Date(1) is equal to (new Date()).toString()');
}

//CHECK#3
if( !isEqual(Date(1970, 1), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1), (new Date()).toString())) {
$ERROR('#3: Date(1970, 1) is equal to (new Date()).toString()');
}

//CHECK#4
if( !isEqual(Date(1970, 1, 1), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1), (new Date()).toString())) {
$ERROR('#4: Date(1970, 1, 1) is equal to (new Date()).toString()');
}

//CHECK#5
if( !isEqual(Date(1970, 1, 1, 1), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1, 1), (new Date()).toString())) {
$ERROR('#5: Date(1970, 1, 1, 1) is equal to (new Date()).toString()');
}

//CHECK#6
if( !isEqual(Date(1970, 1, 1, 1), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1, 1), (new Date()).toString())) {
$ERROR('#7: Date(1970, 1, 1, 1) is equal to (new Date()).toString()');
}

//CHECK#8
if( !isEqual(Date(1970, 1, 1, 1, 0), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1, 1, 0), (new Date()).toString())) {
$ERROR('#8: Date(1970, 1, 1, 1, 0) is equal to (new Date()).toString()');
}

//CHECK#9
if( !isEqual(Date(1970, 1, 1, 1, 0, 0), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1, 1, 0, 0), (new Date()).toString())) {
$ERROR('#9: Date(1970, 1, 1, 1, 0, 0) is equal to (new Date()).toString()');
}

//CHECK#10
if( !isEqual(Date(1970, 1, 1, 1, 0, 0, 0), (new Date()).toString()) ) {
if (!isEqual(Date(1970, 1, 1, 1, 0, 0, 0), (new Date()).toString())) {
$ERROR('#10: Date(1970, 1, 1, 1, 0, 0, 0) is equal to (new Date()).toString()');
}

//CHECK#11
if( !isEqual(Date(Number.NaN), (new Date()).toString()) ) {
if (!isEqual(Date(Number.NaN), (new Date()).toString())) {
$ERROR('#11: Date(Number.NaN) is equal to (new Date()).toString()');
}

//CHECK#12
if( !isEqual(Date(Number.POSITIVE_INFINITY), (new Date()).toString()) ) {
if (!isEqual(Date(Number.POSITIVE_INFINITY), (new Date()).toString())) {
$ERROR('#12: Date(Number.POSITIVE_INFINITY) is equal to (new Date()).toString()');
}

//CHECK#13
if( !isEqual(Date(Number.NEGATIVE_INFINITY), (new Date()).toString()) ) {
if (!isEqual(Date(Number.NEGATIVE_INFINITY), (new Date()).toString())) {
$ERROR('#13: Date(Number.NEGATIVE_INFINITY) is equal to (new Date()).toString()');
}

//CHECK#14
if( !isEqual(Date(undefined), (new Date()).toString()) ) {
if (!isEqual(Date(undefined), (new Date()).toString())) {
$ERROR('#14: Date(undefined) is equal to (new Date()).toString()');
}

//CHECK#15
if( !isEqual(Date(null), (new Date()).toString()) ) {
if (!isEqual(Date(null), (new Date()).toString())) {
$ERROR('#15: Date(null) is equal to (new Date()).toString()');
}
48 changes: 24 additions & 24 deletions test/built-ins/Date/S15.9.3.1_A1_T1.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ if (new Date(1899, 11) === undefined) {
}

var x13 = new Date(1899, 11);
if(typeof x13 !== "object"){
if (typeof x13 !== "object") {
$ERROR("#1.3: typeof new Date(1899, 11) should be 'object'");
}

var x14 = new Date(1899, 11);
if(x14 === undefined){
if (x14 === undefined) {
$ERROR("#1.4: new Date(1899, 11) should not be undefined");
}

Expand All @@ -37,12 +37,12 @@ if (new Date(1899, 12) === undefined) {
}

var x23 = new Date(1899, 12);
if(typeof x23 !== "object"){
if (typeof x23 !== "object") {
$ERROR("#2.3: typeof new Date(1899, 12) should be 'object'");
}

var x24 = new Date(1899, 12);
if(x24 === undefined){
if (x24 === undefined) {
$ERROR("#2.4: new Date(1899, 12) should not be undefined");
}

Expand All @@ -55,12 +55,12 @@ if (new Date(1900, 0) === undefined) {
}

var x33 = new Date(1900, 0);
if(typeof x33 !== "object"){
if (typeof x33 !== "object") {
$ERROR("#3.3: typeof new Date(1900, 0) should be 'object'");
}

var x34 = new Date(1900, 0);
if(x34 === undefined){
if (x34 === undefined) {
$ERROR("#3.4: new Date(1900, 0) should not be undefined");
}

Expand All @@ -73,12 +73,12 @@ if (new Date(1969, 11) === undefined) {
}

var x43 = new Date(1969, 11);
if(typeof x43 !== "object"){
if (typeof x43 !== "object") {
$ERROR("#4.3: typeof new Date(1969, 11) should be 'object'");
}

var x44 = new Date(1969, 11);
if(x44 === undefined){
if (x44 === undefined) {
$ERROR("#4.4: new Date(1969, 11) should not be undefined");
}

Expand All @@ -91,12 +91,12 @@ if (new Date(1969, 12) === undefined) {
}

var x53 = new Date(1969, 12);
if(typeof x53 !== "object"){
if (typeof x53 !== "object") {
$ERROR("#5.3: typeof new Date(1969, 12) should be 'object'");
}

var x54 = new Date(1969, 12);
if(x54 === undefined){
if (x54 === undefined) {
$ERROR("#5.4: new Date(1969, 12) should not be undefined");
}

Expand All @@ -109,12 +109,12 @@ if (new Date(1970, 0) === undefined) {
}

var x63 = new Date(1970, 0);
if(typeof x63 !== "object"){
if (typeof x63 !== "object") {
$ERROR("#6.3: typeof new Date(1970, 0) should be 'object'");
}

var x64 = new Date(1970, 0);
if(x64 === undefined){
if (x64 === undefined) {
$ERROR("#6.4: new Date(1970, 0) should not be undefined");
}

Expand All @@ -127,12 +127,12 @@ if (new Date(1999, 11) === undefined) {
}

var x73 = new Date(1999, 11);
if(typeof x73 !== "object"){
if (typeof x73 !== "object") {
$ERROR("#7.3: typeof new Date(1999, 11) should be 'object'");
}

var x74 = new Date(1999, 11);
if(x74 === undefined){
if (x74 === undefined) {
$ERROR("#7.4: new Date(1999, 11) should not be undefined");
}

Expand All @@ -145,12 +145,12 @@ if (new Date(1999, 12) === undefined) {
}

var x83 = new Date(1999, 12);
if(typeof x83 !== "object"){
if (typeof x83 !== "object") {
$ERROR("#8.3: typeof new Date(1999, 12) should be 'object'");
}

var x84 = new Date(1999, 12);
if(x84 === undefined){
if (x84 === undefined) {
$ERROR("#8.4: new Date(1999, 12) should not be undefined");
}

Expand All @@ -163,12 +163,12 @@ if (new Date(2000, 0) === undefined) {
}

var x93 = new Date(2000, 0);
if(typeof x93 !== "object"){
if (typeof x93 !== "object") {
$ERROR("#9.3: typeof new Date(2000, 0) should be 'object'");
}

var x94 = new Date(2000, 0);
if(x94 === undefined){
if (x94 === undefined) {
$ERROR("#9.4: new Date(2000, 0) should not be undefined");
}

Expand All @@ -181,12 +181,12 @@ if (new Date(2099, 11) === undefined) {
}

var x103 = new Date(2099, 11);
if(typeof x103 !== "object"){
if (typeof x103 !== "object") {
$ERROR("#10.3: typeof new Date(2099, 11) should be 'object'");
}

var x104 = new Date(2099, 11);
if(x104 === undefined){
if (x104 === undefined) {
$ERROR("#10.4: new Date(2099, 11) should not be undefined");
}

Expand All @@ -199,12 +199,12 @@ if (new Date(2099, 12) === undefined) {
}

var x113 = new Date(2099, 12);
if(typeof x113 !== "object"){
if (typeof x113 !== "object") {
$ERROR("#11.3: typeof new Date(2099, 12) should be 'object'");
}

var x114 = new Date(2099, 12);
if(x114 === undefined){
if (x114 === undefined) {
$ERROR("#11.4: new Date(2099, 12) should not be undefined");
}

Expand All @@ -217,11 +217,11 @@ if (new Date(2100, 0) === undefined) {
}

var x123 = new Date(2100, 0);
if(typeof x123 !== "object"){
if (typeof x123 !== "object") {
$ERROR("#12.3: typeof new Date(2100, 0) should be 'object'");
}

var x124 = new Date(2100, 0);
if(x124 === undefined){
if (x124 === undefined) {
$ERROR("#12.4: new Date(2100, 0) should not be undefined");
}
Loading

0 comments on commit b59d956

Please sign in to comment.