Fix tests from jerry-test-suite.

This commit is contained in:
Ilmir Usmanov 2014-10-16 18:03:35 +04:00
parent 2637911b3e
commit 2a5cbe5975
30 changed files with 35 additions and 31 deletions

View File

@ -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)))
assert(!(((new Number(1) - 1 !== 0) || (1 - new Number(1) !== 0))))

View File

@ -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)
assert(!(Number.MIN_VALUE + -Number.MIN_VALUE !== +0))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = NaN, y = 1
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 2, y = NaN
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 2.8, y = 3.4
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = "abg", y = 'abh'
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = "abg", y = 'aBg'
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = false, y = true
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 0.123, y = "0.124"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 0.123, y = "0.123e+2"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 0.123, y = "0.123a"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 0.123, y = "b0.123"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = true, y = "-1"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = true, y = "true"
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = true, y = "123"
assert(x == y)
assert(!(x == y))

View File

@ -15,4 +15,4 @@
var x = Object("abc")
var y = Object("abc")
b = x, c = y
assert(c == b)
assert(!(c == b))

View File

@ -14,4 +14,4 @@
var x = "a"
var y = 2
assert(x == y)
assert(!(x == y))

View File

@ -13,4 +13,4 @@
// limitations under the License.
var x = 0.123, y = "0.123e+2"
assert(x == y)
assert(!(x == y))

View File

@ -14,4 +14,4 @@
var x = "12.1e5"
var y = 1210000
assert(x != y)
assert(!(x != y))

View File

@ -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)
var x = 123.00, y = 0.0123e+4, eps = .000001
assert(x <= y + eps && x >= y - eps)

View File

@ -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)
var x = 123.00, y = 0.0123e+4, eps = .000001
assert(x <= y + eps && x >= y - eps)

View File

@ -14,4 +14,4 @@
var a = true;
var b = false;
assert((a && b) === true)
assert(!((a && b) === true))

View File

@ -14,4 +14,4 @@
var a = false;
var b = false;
assert((a && b) === true)
assert(!((a && b) === true))

View File

@ -14,4 +14,4 @@
var a = "not empty string"; // will be converted to true
var b = new Object();
assert((a && b) !== b)
assert(!((a && b) !== b))

View File

@ -14,4 +14,4 @@
var a = ""; // empty string - false
var b = new Object();
assert((a && b) !== a)
assert(!((a && b) !== a))

View File

@ -15,4 +15,4 @@
var a = Number;
Number = null;
var b = new a(5)
assert(b === 5);
assert(!(b === 5));

View File

@ -12,4 +12,4 @@
// See the License for the specific language governing permissions and
// limitations under the License.
assert(delete Number.NaN);
assert(!(delete Number.NaN));

View File

@ -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));

View File

@ -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));

View File

@ -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