1 // |reftest| skip -- Intl.Locale-info is not supported
2 // Copyright 2023 Google Inc. All rights reserved.
3 // This code is governed by the BSD license found in the LICENSE file.
8 Checks error cases for the options argument to the Locale constructor.
10 Intl.Locale( tag [, options] )
13 x. Let numberingSystem be ? GetOption(options, "firstDayOfWeek", "string", < *"mon"*, *"tue"*, *"wed"*, *"thu"*, *"fri"*, *"sat"*, *"sun"*, *"0"*, *"1"*, *"2"*, *"3"*, *"4"*, *"5"*, *"6"*, *"7"*> , undefined).
16 features: [Intl.Locale,Intl.Locale-info]
19 const invalidFirstDayOfWeekOptions = [
28 for (const firstDayOfWeek of invalidFirstDayOfWeekOptions) {
29 assert.throws(RangeError, function() {
30 new Intl.Locale('en', {firstDayOfWeek});
31 }, `new Intl.Locale("en", {firstDayOfWeek: "${firstDayOfWeek}"}) throws RangeError`);