install-node: Upgrade Node.js from 18.14.1 to 18.15.0.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg 2023-03-16 11:40:55 -07:00 committed by Tim Abbott
parent 330141f55d
commit 96e657a954
5 changed files with 27 additions and 27 deletions

View File

@ -1,18 +1,18 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
version=18.14.1 version=18.15.0
arch="$(uname -m)" arch="$(uname -m)"
case $arch in case $arch in
x86_64) x86_64)
tarball="node-v$version-linux-x64.tar.xz" tarball="node-v$version-linux-x64.tar.xz"
sha256=ea3bd72ad5ccaa1d9bcb40da69a60f249d29672d41740fe8f3e976d0e9078f65 sha256=c8c5fa53ce0c0f248e45983e86368e0b1daf84b77e88b310f769c3cfc12682ef
;; ;;
aarch64) aarch64)
tarball="node-v$version-linux-arm64.tar.xz" tarball="node-v$version-linux-arm64.tar.xz"
sha256=52f33439dcca865bbb70194091f6ce0c02b2a32d5a744901f175fff1ca6d0c86 sha256=98ea6ed0a1ae55334ab2c03c34d5e52c6dc3dee8f236c0afc08ab1c964506633
;; ;;
esac esac

View File

@ -48,4 +48,4 @@ API_FEATURE_LEVEL = 168
# historical commits sharing the same major version, in which case a # historical commits sharing the same major version, in which case a
# minor version bump suffices. # minor version bump suffices.
PROVISION_VERSION = (224, 2) PROVISION_VERSION = (224, 3)

View File

@ -520,7 +520,7 @@ test("format_drafts", ({override_rewire, mock_template}) => {
dark_background: "", dark_background: "",
topic: "topic", topic: "topic",
raw_content: "Test stream message", raw_content: "Test stream message",
time_stamp: "7:55AM", time_stamp: "7:55 AM",
}, },
{ {
draft_id: "id2", draft_id: "id2",
@ -685,7 +685,7 @@ test("filter_drafts", ({override_rewire, mock_template}) => {
dark_background: "", dark_background: "",
topic: "topic", topic: "topic",
raw_content: "Test stream message", raw_content: "Test stream message",
time_stamp: "7:55AM", time_stamp: "7:55 AM",
}, },
{ {
draft_id: "id3", draft_id: "id3",

View File

@ -251,7 +251,7 @@ run_test("timestamp without time", () => {
run_test("timestamp", ({mock_template}) => { run_test("timestamp", ({mock_template}) => {
mock_template("markdown_timestamp.hbs", true, (data, html) => { mock_template("markdown_timestamp.hbs", true, (data, html) => {
assert.deepEqual(data, {text: "Thu, Jan 1, 1970, 12:00AM"}); assert.deepEqual(data, {text: "Thu, Jan 1, 1970, 12:00 AM"});
return html; return html;
}); });
@ -271,7 +271,7 @@ run_test("timestamp", ({mock_template}) => {
rm.update_elements($content); rm.update_elements($content);
// Final asserts // Final asserts
assert.equal($timestamp.html(), '<i class="fa fa-clock-o"></i>\nThu, Jan 1, 1970, 12:00AM\n'); assert.equal($timestamp.html(), '<i class="fa fa-clock-o"></i>\nThu, Jan 1, 1970, 12:00 AM\n');
assert.equal($timestamp_invalid.text(), "never-been-set"); assert.equal($timestamp_invalid.text(), "never-been-set");
}); });
@ -294,7 +294,7 @@ run_test("timestamp-twenty-four-hour-time", ({mock_template, override}) => {
override(user_settings, "twenty_four_hour_time", false); override(user_settings, "twenty_four_hour_time", false);
rm.update_elements($content); rm.update_elements($content);
assert.equal($timestamp.html(), '<i class="fa fa-clock-o"></i>\nWed, Jul 15, 2020, 8:40PM\n'); assert.equal($timestamp.html(), '<i class="fa fa-clock-o"></i>\nWed, Jul 15, 2020, 8:40 PM\n');
}); });
run_test("timestamp-error", () => { run_test("timestamp-error", () => {

View File

@ -54,13 +54,13 @@ run_test("get_localized_date_or_time_for_format returns correct format", () => {
{ {
format: "time", format: "time",
expected: { expected: {
date: "1:53AM", date: "1:53 AM",
}, },
}, },
{ {
format: "time_sec", format: "time_sec",
expected: { expected: {
date: "1:53:08AM", date: "1:53:08 AM",
}, },
}, },
{ {
@ -78,7 +78,7 @@ run_test("get_localized_date_or_time_for_format returns correct format", () => {
{ {
format: "dayofyear_time", format: "dayofyear_time",
expected: { expected: {
date: "Jan 27, 1:53AM", date: "Jan 27, 1:53 AM",
}, },
}, },
{ {
@ -90,7 +90,7 @@ run_test("get_localized_date_or_time_for_format returns correct format", () => {
{ {
format: "dayofyear_year_time", format: "dayofyear_year_time",
expected: { expected: {
date: "Jan 27, 2021, 1:53AM", date: "Jan 27, 2021, 1:53 AM",
}, },
}, },
{ {
@ -102,7 +102,7 @@ run_test("get_localized_date_or_time_for_format returns correct format", () => {
{ {
format: "weekday_dayofyear_year_time", format: "weekday_dayofyear_year_time",
expected: { expected: {
date: "Wed, Jan 27, 2021, 1:53AM", date: "Wed, Jan 27, 2021, 1:53 AM",
}, },
}, },
]; ];
@ -125,7 +125,7 @@ run_test("get_localized_date_or_time_for_format returns correct localized date",
{ {
language: "ru", language: "ru",
expected: { expected: {
date: "четверг, 12 апреля 2018г.", date: "четверг, 12 апреля 2018 г.",
}, },
}, },
{ {
@ -259,7 +259,7 @@ run_test("format_time_modern", () => {
assert.equal(timerender.format_time_modern(few_minutes_in_future, today), "Jan 27, 2021"); assert.equal(timerender.format_time_modern(few_minutes_in_future, today), "Jan 27, 2021");
assert.equal(timerender.format_time_modern(weeks_in_future, today), "Feb 16, 2021"); assert.equal(timerender.format_time_modern(weeks_in_future, today), "Feb 16, 2021");
assert.equal(timerender.format_time_modern(less_than_24_hours_ago, today), "2:53AM"); assert.equal(timerender.format_time_modern(less_than_24_hours_ago, today), "2:53 AM");
assert.equal( assert.equal(
timerender.format_time_modern(twenty_four_hours_ago, today), timerender.format_time_modern(twenty_four_hours_ago, today),
"translated: Yesterday", "translated: Yesterday",
@ -287,7 +287,7 @@ run_test("format_time_modern_different_timezones", () => {
assert.equal(timerender.format_time_modern(yesterday, today), "translated: Yesterday"); assert.equal(timerender.format_time_modern(yesterday, today), "translated: Yesterday");
process.env.TZ = "America/Juneau"; process.env.TZ = "America/Juneau";
let expected = "translated: 5/16/2017 at 11:12:53PM AKDT (UTC-08:00)"; let expected = "translated: 5/16/2017 at 11:12:53 PM AKDT (UTC-08:00)";
assert.equal(timerender.get_full_datetime(yesterday), expected); assert.equal(timerender.get_full_datetime(yesterday), expected);
assert.equal(timerender.format_time_modern(yesterday, today), "Tuesday"); assert.equal(timerender.format_time_modern(yesterday, today), "Tuesday");
process.env.TZ = utc_tz; process.env.TZ = utc_tz;
@ -298,7 +298,7 @@ run_test("format_time_modern_different_timezones", () => {
assert.equal(timerender.format_time_modern(yesterday, today), "Tuesday"); assert.equal(timerender.format_time_modern(yesterday, today), "Tuesday");
process.env.TZ = "Asia/Brunei"; process.env.TZ = "Asia/Brunei";
expected = "translated: 5/17/2017 at 5:12:53AM (UTC+08:00)"; expected = "translated: 5/17/2017 at 5:12:53 AM (UTC+08:00)";
assert.equal(timerender.get_full_datetime(yesterday), expected); assert.equal(timerender.get_full_datetime(yesterday), expected);
assert.equal(timerender.format_time_modern(yesterday, today), "translated: Yesterday"); assert.equal(timerender.format_time_modern(yesterday, today), "translated: Yesterday");
process.env.TZ = utc_tz; process.env.TZ = utc_tz;
@ -309,7 +309,7 @@ run_test("format_time_modern_different_timezones", () => {
assert.equal(timerender.format_time_modern(yesterday, today), "Friday"); assert.equal(timerender.format_time_modern(yesterday, today), "Friday");
process.env.TZ = "America/Juneau"; process.env.TZ = "America/Juneau";
expected = "translated: 5/11/2017 at 11:12:53PM AKDT (UTC-08:00)"; expected = "translated: 5/11/2017 at 11:12:53 PM AKDT (UTC-08:00)";
assert.equal(timerender.get_full_datetime(yesterday), expected); assert.equal(timerender.get_full_datetime(yesterday), expected);
assert.equal(timerender.format_time_modern(yesterday, today), "May 11"); assert.equal(timerender.format_time_modern(yesterday, today), "May 11");
process.env.TZ = utc_tz; process.env.TZ = utc_tz;
@ -386,13 +386,13 @@ run_test("absolute_time_12_hour", () => {
let timestamp = date_2019.getTime(); let timestamp = date_2019.getTime();
let today = date_2019; let today = date_2019;
let expected = "Apr 12, 5:52PM"; let expected = "Apr 12, 5:52 PM";
let actual = timerender.absolute_time(timestamp, today); let actual = timerender.absolute_time(timestamp, today);
assert.equal(actual, expected); assert.equal(actual, expected);
// timestamp with hour > 12, different year // timestamp with hour > 12, different year
let next_year = add(today, {years: 1}); let next_year = add(today, {years: 1});
expected = "Apr 12, 2019, 5:52PM"; expected = "Apr 12, 2019, 5:52 PM";
actual = timerender.absolute_time(timestamp, next_year); actual = timerender.absolute_time(timestamp, next_year);
assert.equal(actual, expected); assert.equal(actual, expected);
@ -400,13 +400,13 @@ run_test("absolute_time_12_hour", () => {
timestamp = date_2017.getTime(); timestamp = date_2017.getTime();
today = date_2017; today = date_2017;
expected = "May 18, 7:12AM"; expected = "May 18, 7:12 AM";
actual = timerender.absolute_time(timestamp, today); actual = timerender.absolute_time(timestamp, today);
assert.equal(actual, expected); assert.equal(actual, expected);
// timestamp with hour < 12, different year // timestamp with hour < 12, different year
next_year = add(today, {years: 1}); next_year = add(today, {years: 1});
expected = "May 18, 2017, 7:12AM"; expected = "May 18, 2017, 7:12 AM";
actual = timerender.absolute_time(timestamp, next_year); actual = timerender.absolute_time(timestamp, next_year);
assert.equal(actual, expected); assert.equal(actual, expected);
}); });
@ -443,7 +443,7 @@ run_test("absolute_time_24_hour", () => {
run_test("get_full_datetime", () => { run_test("get_full_datetime", () => {
const time = date_2017_PM; const time = date_2017_PM;
let expected = "translated: 5/18/2017 at 9:12:53PM UTC"; let expected = "translated: 5/18/2017 at 9:12:53 PM UTC";
assert.equal(timerender.get_full_datetime(time), expected); assert.equal(timerender.get_full_datetime(time), expected);
// test 24 hour time setting. // test 24 hour time setting.
@ -456,7 +456,7 @@ run_test("get_full_datetime", () => {
// Test the GMT[+-]x:y logic. // Test the GMT[+-]x:y logic.
const previous_env_tz = process.env.TZ; const previous_env_tz = process.env.TZ;
process.env.TZ = "Asia/Kolkata"; process.env.TZ = "Asia/Kolkata";
expected = "translated: 5/19/2017 at 2:42:53AM (UTC+05:30)"; expected = "translated: 5/19/2017 at 2:42:53 AM (UTC+05:30)";
assert.equal(timerender.get_full_datetime(time), expected); assert.equal(timerender.get_full_datetime(time), expected);
process.env.TZ = previous_env_tz; process.env.TZ = previous_env_tz;
}); });
@ -526,12 +526,12 @@ run_test("set_full_datetime", () => {
user_settings.twenty_four_hour_time = false; user_settings.twenty_four_hour_time = false;
time_str = timerender.stringify_time(time); time_str = timerender.stringify_time(time);
expected = "5:52PM"; expected = "5:52 PM";
assert.equal(time_str, expected); assert.equal(time_str, expected);
time = add(time, {hours: -7}); // time between 1 to 12 o'clock time. time = add(time, {hours: -7}); // time between 1 to 12 o'clock time.
user_settings.twenty_four_hour_time = false; user_settings.twenty_four_hour_time = false;
time_str = timerender.stringify_time(time); time_str = timerender.stringify_time(time);
expected = "10:52AM"; expected = "10:52 AM";
assert.equal(time_str, expected); assert.equal(time_str, expected);
}); });