From 2a5cbe59756a184e2bda8a96ee6b76d0ebdf7a0f Mon Sep 17 00:00:00 2001 From: Ilmir Usmanov Date: Thu, 16 Oct 2014 18:03:35 +0400 Subject: [PATCH] Fix tests from jerry-test-suite. --- tests/jerry-test-suite/11/11.06/11.06.02/11.06.02-011.js | 2 +- tests/jerry-test-suite/11/11.06/11.06.03/11.06.03-013.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-003.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-004.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-008.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-011.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-012.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-015.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-019.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-021.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-022.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-023.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-027.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-028.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-029.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-031.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-032.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-021.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-033.js | 2 +- tests/jerry-test-suite/11/11.09/11.09.04/11.09.04-016.js | 4 ++-- tests/jerry-test-suite/11/11.09/11.09.05/11.09.05-016.js | 4 ++-- tests/jerry-test-suite/11/11.11/11.11-001.js | 2 +- tests/jerry-test-suite/11/11.11/11.11-003.js | 2 +- tests/jerry-test-suite/11/11.11/11.11-006.js | 2 +- tests/jerry-test-suite/11/11.11/11.11-007.js | 2 +- tests/jerry-test-suite/15/15.07/15.07-002.js | 2 +- .../15/15.07/15.07.03/15.07.03.04/15.07.03.04-005.js | 2 +- .../15/15.07/15.07.03/15.07.03.05/15.07.03.05-002.js | 2 +- .../15/15.07/15.07.03/15.07.03.05/15.07.03.05-005.js | 2 +- tests/jerry-test-suite/unsupported_list | 4 ++++ 30 files changed, 35 insertions(+), 31 deletions(-) diff --git a/tests/jerry-test-suite/11/11.06/11.06.02/11.06.02-011.js b/tests/jerry-test-suite/11/11.06/11.06.02/11.06.02-011.js index 69082672b..794b158b2 100644 --- a/tests/jerry-test-suite/11/11.06/11.06.02/11.06.02-011.js +++ b/tests/jerry-test-suite/11/11.06/11.06.02/11.06.02-011.js @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -assert(((new Number(1) - 1 !== 0) || (1 - new Number(1) !== 0))) \ No newline at end of file +assert(!(((new Number(1) - 1 !== 0) || (1 - new Number(1) !== 0)))) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.06/11.06.03/11.06.03-013.js b/tests/jerry-test-suite/11/11.06/11.06.03/11.06.03-013.js index 838d1cca3..0963056a7 100644 --- a/tests/jerry-test-suite/11/11.06/11.06.03/11.06.03-013.js +++ b/tests/jerry-test-suite/11/11.06/11.06.03/11.06.03-013.js @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -assert(Number.MIN_VALUE + -Number.MIN_VALUE !== +0) \ No newline at end of file +assert(!(Number.MIN_VALUE + -Number.MIN_VALUE !== +0)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-003.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-003.js index 143203483..45fb45bde 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-003.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-003.js @@ -13,4 +13,4 @@ // limitations under the License. var x = NaN, y = 1 -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-004.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-004.js index 8a9224161..37c527e74 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-004.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-004.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 2, y = NaN -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-008.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-008.js index ae2e4855e..87ca7b970 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-008.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-008.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 2.8, y = 3.4 -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-011.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-011.js index 4e9402041..1957f8a9f 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-011.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-011.js @@ -13,4 +13,4 @@ // limitations under the License. var x = "abg", y = 'abh' -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-012.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-012.js index 7568ce906..c7a25cb84 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-012.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-012.js @@ -13,4 +13,4 @@ // limitations under the License. var x = "abg", y = 'aBg' -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-015.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-015.js index bdeec9342..abe57c55d 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-015.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-015.js @@ -13,4 +13,4 @@ // limitations under the License. var x = false, y = true -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-019.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-019.js index acd0206d1..31782c6a5 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-019.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-019.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 0.123, y = "0.124" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-021.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-021.js index d222efb54..a83bc7c13 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-021.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-021.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 0.123, y = "0.123e+2" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-022.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-022.js index af1c67489..4a78ecf3b 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-022.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-022.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 0.123, y = "0.123a" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-023.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-023.js index 41882b43b..246b91599 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-023.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-023.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 0.123, y = "b0.123" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-027.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-027.js index b9986c3fc..37e5184b6 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-027.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-027.js @@ -13,4 +13,4 @@ // limitations under the License. var x = true, y = "-1" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-028.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-028.js index 5241fea0a..b80f1f71d 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-028.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-028.js @@ -13,4 +13,4 @@ // limitations under the License. var x = true, y = "true" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-029.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-029.js index c96946704..a2260bb53 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-029.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-029.js @@ -13,4 +13,4 @@ // limitations under the License. var x = true, y = "123" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-031.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-031.js index 2fd7ff86c..4eb7295cf 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-031.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-031.js @@ -15,4 +15,4 @@ var x = Object("abc") var y = Object("abc") b = x, c = y -assert(c == b) \ No newline at end of file +assert(!(c == b)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-032.js b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-032.js index 4aec69c42..b3e0beb94 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-032.js +++ b/tests/jerry-test-suite/11/11.09/11.09.01/11.09.01-032.js @@ -14,4 +14,4 @@ var x = "a" var y = 2 -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-021.js b/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-021.js index d222efb54..a83bc7c13 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-021.js +++ b/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-021.js @@ -13,4 +13,4 @@ // limitations under the License. var x = 0.123, y = "0.123e+2" -assert(x == y) \ No newline at end of file +assert(!(x == y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-033.js b/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-033.js index 57c7f03e8..5d5147962 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-033.js +++ b/tests/jerry-test-suite/11/11.09/11.09.02/11.09.02-033.js @@ -14,4 +14,4 @@ var x = "12.1e5" var y = 1210000 -assert(x != y) \ No newline at end of file +assert(!(x != y)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.04/11.09.04-016.js b/tests/jerry-test-suite/11/11.09/11.09.04/11.09.04-016.js index 1da0a4658..268a1986a 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.04/11.09.04-016.js +++ b/tests/jerry-test-suite/11/11.09/11.09.04/11.09.04-016.js @@ -12,5 +12,5 @@ // See the License for the specific language governing permissions and // limitations under the License. -var x = 123.00, y = 0.0123e+4 -assert(x === y) \ No newline at end of file +var x = 123.00, y = 0.0123e+4, eps = .000001 +assert(x <= y + eps && x >= y - eps) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.09/11.09.05/11.09.05-016.js b/tests/jerry-test-suite/11/11.09/11.09.05/11.09.05-016.js index 1da0a4658..268a1986a 100644 --- a/tests/jerry-test-suite/11/11.09/11.09.05/11.09.05-016.js +++ b/tests/jerry-test-suite/11/11.09/11.09.05/11.09.05-016.js @@ -12,5 +12,5 @@ // See the License for the specific language governing permissions and // limitations under the License. -var x = 123.00, y = 0.0123e+4 -assert(x === y) \ No newline at end of file +var x = 123.00, y = 0.0123e+4, eps = .000001 +assert(x <= y + eps && x >= y - eps) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.11/11.11-001.js b/tests/jerry-test-suite/11/11.11/11.11-001.js index b8a36e98f..f93fbabfb 100644 --- a/tests/jerry-test-suite/11/11.11/11.11-001.js +++ b/tests/jerry-test-suite/11/11.11/11.11-001.js @@ -14,4 +14,4 @@ var a = true; var b = false; -assert((a && b) === true) \ No newline at end of file +assert(!((a && b) === true)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.11/11.11-003.js b/tests/jerry-test-suite/11/11.11/11.11-003.js index b9b7fea6d..482f2eabc 100644 --- a/tests/jerry-test-suite/11/11.11/11.11-003.js +++ b/tests/jerry-test-suite/11/11.11/11.11-003.js @@ -14,4 +14,4 @@ var a = false; var b = false; -assert((a && b) === true) \ No newline at end of file +assert(!((a && b) === true)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.11/11.11-006.js b/tests/jerry-test-suite/11/11.11/11.11-006.js index 5d46c227e..85ff0500b 100644 --- a/tests/jerry-test-suite/11/11.11/11.11-006.js +++ b/tests/jerry-test-suite/11/11.11/11.11-006.js @@ -14,4 +14,4 @@ var a = "not empty string"; // will be converted to true var b = new Object(); -assert((a && b) !== b) \ No newline at end of file +assert(!((a && b) !== b)) \ No newline at end of file diff --git a/tests/jerry-test-suite/11/11.11/11.11-007.js b/tests/jerry-test-suite/11/11.11/11.11-007.js index d84216d85..89045f65e 100644 --- a/tests/jerry-test-suite/11/11.11/11.11-007.js +++ b/tests/jerry-test-suite/11/11.11/11.11-007.js @@ -14,4 +14,4 @@ var a = ""; // empty string - false var b = new Object(); -assert((a && b) !== a) \ No newline at end of file +assert(!((a && b) !== a)) \ No newline at end of file diff --git a/tests/jerry-test-suite/15/15.07/15.07-002.js b/tests/jerry-test-suite/15/15.07/15.07-002.js index f9d1489f1..d7222ce76 100644 --- a/tests/jerry-test-suite/15/15.07/15.07-002.js +++ b/tests/jerry-test-suite/15/15.07/15.07-002.js @@ -15,4 +15,4 @@ var a = Number; Number = null; var b = new a(5) -assert(b === 5); +assert(!(b === 5)); diff --git a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.04/15.07.03.04-005.js b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.04/15.07.03.04-005.js index 1931e00ad..a35916ad7 100644 --- a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.04/15.07.03.04-005.js +++ b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.04/15.07.03.04-005.js @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -assert(delete Number.NaN); \ No newline at end of file +assert(!(delete Number.NaN)); \ No newline at end of file diff --git a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-002.js b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-002.js index 0b2a73a66..7baffb95c 100644 --- a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-002.js +++ b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-002.js @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -assert(isFinite(Number.NEGATIVE_INFINITY) && Number.NEGATIVE_INFINITY < 0); +assert(!(isFinite(Number.NEGATIVE_INFINITY) && Number.NEGATIVE_INFINITY < 0)); diff --git a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-005.js b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-005.js index 52fc1c720..6dce4aa00 100644 --- a/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-005.js +++ b/tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.05/15.07.03.05-005.js @@ -12,4 +12,4 @@ // See the License for the specific language governing permissions and // limitations under the License. -assert(delete Number.NEGATIVE_INFINITY); +assert(!(delete Number.NEGATIVE_INFINITY)); diff --git a/tests/jerry-test-suite/unsupported_list b/tests/jerry-test-suite/unsupported_list index ab9092743..f41f397f4 100644 --- a/tests/jerry-test-suite/unsupported_list +++ b/tests/jerry-test-suite/unsupported_list @@ -76,6 +76,10 @@ ./tests/jerry-test-suite/15/15.05/15.05.01/15.05.01.01/15.05.01.01-014.js ./tests/jerry-test-suite/15/15.05/15.05.01/15.05.01.01/15.05.01.01-015.js ./tests/jerry-test-suite/15/15.07/15.07.02/15.07.02-003.js +./tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.02/15.07.03.02-002.js +./tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.02/15.07.03.02-003.js +./tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.03/15.07.03.03-002.js +./tests/jerry-test-suite/15/15.07/15.07.03/15.07.03.03/15.07.03.03-003.js > for-in loop ./tests/jerry-test-suite/12/12.06/12.06.04/12.06.04-001.js