xref: /expo/apps/test-suite/tests/JSC.js (revision 56b1fb19)
1export const name = 'JSC';
2
3export function test(t) {
4  t.describe('JSC', () => {
5    t.it('defines the Symbol global variable and symbol primitive', () => {
6      t.expect(Symbol).toBeDefined();
7      const test = Symbol('test');
8      t.expect(typeof test).toEqual('symbol');
9    });
10    t.it('does not use intl variant', () => {
11      const opts = { weekday: 'long', year: 'numeric', month: 'long', day: 'numeric' };
12      const date = new Date();
13      const he = date.toLocaleDateString('he', opts);
14      const us = date.toLocaleDateString('en-US', opts);
15      t.expect(he).toEqual(us);
16    });
17  });
18}
19