Change 'assert' handle to pass only upon exactly 1 argument is received, and the argument is boolean true; update internal test suite correspondingly.

JerryScript-DCO-1.0-Signed-off-by: Ruben Ayrapetyan r.ayrapetyan@samsung.com
This commit is contained in:
Ruben Ayrapetyan
2015-07-30 15:13:16 +03:00
parent 5d385b1144
commit c715a7cd1d
44 changed files with 138 additions and 137 deletions
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String() === String("") ? 1 : 0);
assert (String () === String (""));
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(undefined) === "undefined" ? 1 : 0);
assert (String (undefined) === "undefined");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(null) === "null" ? 1 : 0);
assert (String (null) === "null");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(true) === "true" ? 1 : 0);
assert (String (true) === "true");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(false) === "false" ? 1 : 0);
assert (String (false) === "false");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(+0) === "0" ? 1 : 0);
assert (String (+0) === "0");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(-0) === "0" ? 1 : 0);
assert (String (-0) === "0");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(-1) === "-" + String(1) ? 1 : 0);
assert (String (-1) === "-" + String (1));
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(Infinity) === "Infinity" ? 1 : 0);
assert (String (Infinity) === "Infinity");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(123000) === "123000" ? 1 : 0);
assert (String (123000) === "123000");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(10000000000000000000) === "10000000000000000000" ? 1 : 0);
assert (String (10000000000000000000) === "10000000000000000000");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(0.111111111111111) === "0.111111111111111" ? 1 : 0);
assert (String (0.111111111111111) === "0.111111111111111");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(0.00000111111111111111) === "0.00000111111111111111" ? 1 : 0);
assert (String (0.00000111111111111111) === "0.00000111111111111111");
@@ -1,4 +1,4 @@
// Copyright 2014 Samsung Electronics Co., Ltd.
// Copyright 2014-2015 Samsung Electronics Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(String(0.000000111111111111111) === "1.11111111111111e-7" ? 1 : 0);
assert (String (0.000000111111111111111) === "1.11111111111111e-7");