From 340dfba5dceef98f70a182aa740eb2c0fe11563c Mon Sep 17 00:00:00 2001
From: Caio Lima <ticaiolima@gmail.com>
Date: Tue, 8 May 2018 09:28:53 -0300
Subject: [PATCH] Added tests for relational comparison among BigInt and Symbol

---
 .../greater-than/bigint-and-symbol.js         | 17 +++++++++++++++++
 .../less-than/bigint-and-symbol.js            | 19 +++++++++++++++++++
 2 files changed, 36 insertions(+)
 create mode 100644 test/language/expressions/greater-than/bigint-and-symbol.js
 create mode 100644 test/language/expressions/less-than/bigint-and-symbol.js

diff --git a/test/language/expressions/greater-than/bigint-and-symbol.js b/test/language/expressions/greater-than/bigint-and-symbol.js
new file mode 100644
index 0000000000..2247f5588c
--- /dev/null
+++ b/test/language/expressions/greater-than/bigint-and-symbol.js
@@ -0,0 +1,17 @@
+// Copyright (C) 2018 Caio Lima. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Relational comparison of BigInt and Symbol values
+esid: sec-abstract-relational-comparison
+features: [BigInt, Symbol]
+---*/
+
+assert.throws(TypeError, function() {
+  3n > Symbol("2");
+}, "ToNumeric(rhs) throws.");
+
+assert.throws(TypeError, function() {
+  Symbol("2") > 3n;
+}, "ToNumeric(rhs) throws.");
+
diff --git a/test/language/expressions/less-than/bigint-and-symbol.js b/test/language/expressions/less-than/bigint-and-symbol.js
new file mode 100644
index 0000000000..e73d70b99f
--- /dev/null
+++ b/test/language/expressions/less-than/bigint-and-symbol.js
@@ -0,0 +1,19 @@
+// Copyright (C) 2018 Caio Lima. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/*---
+description: Relational comparison of BigInt and Symbol values
+esid: sec-abstract-relational-comparison
+features: [BigInt, Symbol]
+---*/
+
+function MyError() {}
+
+assert.throws(TypeError, function() {
+  3n < Symbol("2");
+}, "ToNumeric(rhs) throws.");
+
+assert.throws(TypeError, function() {
+  Symbol("2") < 3n;
+}, "ToNumeric(rhs) throws.");
+
-- 
GitLab