<commit_before>import { getResolvedLocale } from '../helpers/get-resolved-locale.js';
import { APP_INDEX_URL } from './constants.js';
import {
  ok, strictEqual,
} from './helpers/typed-assert.js';

describe('timezones', () => {
  before(async () => {
    await browser.url(APP_INDEX_URL);
  });

  function hasFullICU() {
    try {
      const january = new Date(9e8);
      const spanish = new Intl.DateTimeFormat('es', { month: 'long' });
      return spanish.format(january) === 'enero';
    } catch (err) {
      return false;
    }
  }

  it(`supports full ICU`, async () => {
    ok(hasFullICU());
    strictEqual(
      Intl.DateTimeFormat('en-US', {
        year: 'numeric',
        month: 'short',
        day: 'numeric',
      }).format(new Date('2020-02-02')),
      'Feb 2, 2020'
    );
    strictEqual(getResolvedLocale(), 'en-US');

    const content = await browser.executeAsync(async (done) => {
      const a = document.createElement('app-datepicker');

      document.body.appendChild(a);

      await a.updateComplete;

      done(
        (a as any)._formatters.fullDateFormat(new Date('2020-03-03'))
        // a.locale,
        // Array.from(
        //   a.shadowRoot?.querySelectorAll('.full-calendar__day') ?? []
        // )[2]?.outerHTML ?? 'nil'
      );
    });

    console.debug('1', content, Intl.DateTimeFormat('en-US', {
      timeZone: 'UTC',
      year: 'numeric',
      month: 'short',
      day: 'numeric',
    }).format(new Date('2020-03-03')));
    strictEqual(content, '');
  });

});<commit_msg>ci: Trying to find out the cause<commit_after>import { getResolvedLocale } from '../helpers/get-resolved-locale.js';
import { APP_INDEX_URL } from './constants.js';
import {
  deepStrictEqual,
  ok,
  strictEqual,
} from './helpers/typed-assert.js';

describe('timezones', () => {
  before(async () => {
    await browser.url(APP_INDEX_URL);
  });

  function hasFullICU() {
    try {
      const january = new Date(9e8);
      const spanish = new Intl.DateTimeFormat('es', { month: 'long' });
      return spanish.format(january) === 'enero';
    } catch (err) {
      return false;
    }
  }

  it(`supports full ICU`, async () => {
    ok(hasFullICU());
    strictEqual(
      Intl.DateTimeFormat('en-US', {
        year: 'numeric',
        month: 'short',
        day: 'numeric',
      }).format(new Date('2020-02-02')),
      'Feb 2, 2020'
    );
    strictEqual(getResolvedLocale(), 'en-US');

    const content = await browser.executeAsync(async (done) => {
      const a = document.createElement('app-datepicker');

      document.body.appendChild(a);

      await a.updateComplete;

      done(
        [
          a.locale,
          (a as any)._formatters.fullDateFormat(new Date('2020-03-03')),
        ]
        // a.locale,
        // Array.from(
        //   a.shadowRoot?.querySelectorAll('.full-calendar__day') ?? []
        // )[2]?.outerHTML ?? 'nil'
      );
    });

    console.debug('1', content, Intl.DateTimeFormat('en-US', {
      timeZone: 'UTC',
      year: 'numeric',
      month: 'short',
      day: 'numeric',
    }).format(new Date('2020-03-03')));
    deepStrictEqual(content, []);
  });

});
{'fraction_non_alphanumeric': 0.18115712930761935, 'fraction_numerical': 0.020866266202971863, 'mean_word_length': 2.507760532150776, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '487646', 'n_tokens_mistral': 1087, 'n_tokens_neox': 1029, 'n_words': 192}