From 921f9a7966b3c6af78993b4ac438bf7d4195fd28 Mon Sep 17 00:00:00 2001 From: Stedoss <29103029+Stedoss@users.noreply.github.com> Date: Tue, 28 Jul 2026 09:50:37 +0100 Subject: [PATCH 1/4] Create simple CI workflow --- .gitea/workflows/build-test.yml | 52 +++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 .gitea/workflows/build-test.yml diff --git a/.gitea/workflows/build-test.yml b/.gitea/workflows/build-test.yml new file mode 100644 index 0000000..7a7ca25 --- /dev/null +++ b/.gitea/workflows/build-test.yml @@ -0,0 +1,52 @@ +name: Build & Test + +on: + push: + branches: + - main + pull_request: + branches: + - '*' + +jobs: + build-backend: + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up .NET + uses: actions/setup-dotnet@v5 + with: + dotnet-version: '10.0.x' + + - name: Restore .NET Tools + run: dotnet tool restore + + - name: Check formatting + run: dotnet csharpier format . + + - name: Build + run: dotnet build + + - name: Test + run: dotnet test + + build-frontend: + defaults: + run: + working-directory: ./src/mission-control-client + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Install dependencies + run: npm ci + + - name: Check formatting + run: npm run format:check + + - name: Build + run: npm run build + + - name: Test + run: npm test \ No newline at end of file -- 2.54.0 From 330e3cb27ec491c12ac409999429b1bf3b9ccd61 Mon Sep 17 00:00:00 2001 From: Stedoss <29103029+Stedoss@users.noreply.github.com> Date: Tue, 28 Jul 2026 09:55:35 +0100 Subject: [PATCH 2/4] Try setting UTC --- .gitea/workflows/build-test.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/build-test.yml b/.gitea/workflows/build-test.yml index 7a7ca25..39fc447 100644 --- a/.gitea/workflows/build-test.yml +++ b/.gitea/workflows/build-test.yml @@ -49,4 +49,6 @@ jobs: run: npm run build - name: Test - run: npm test \ No newline at end of file + run: npm test + env: + TZ: UTC \ No newline at end of file -- 2.54.0 From e75da669681244cdbeee2e344c39fb1bb32da12f Mon Sep 17 00:00:00 2001 From: Stedoss <29103029+Stedoss@users.noreply.github.com> Date: Tue, 28 Jul 2026 09:02:36 +0000 Subject: [PATCH 3/4] Fix test --- src/mission-control-client/src/utils/dateUtils.test.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mission-control-client/src/utils/dateUtils.test.ts b/src/mission-control-client/src/utils/dateUtils.test.ts index f20519a..3bd83cc 100644 --- a/src/mission-control-client/src/utils/dateUtils.test.ts +++ b/src/mission-control-client/src/utils/dateUtils.test.ts @@ -20,7 +20,8 @@ describe('dateUtils', () => { it('returns readable date when datetime passed is in valid format', () => { const date = toReadableDateTime('2026-07-27T23:27:22.1976394+00:00'); - expect(date).toBe('27/07/2026, 23:27:22'); + // Date invariants are annoying, test that we are getting back the locale in this case + expect(date).toBe(new Date('2026-07-27T23:27:22.1976394+00:00').toLocaleString()); }); }); }); -- 2.54.0 From e0043533b8bd5cee3ab4350c3fc3604fd98641ad Mon Sep 17 00:00:00 2001 From: Stedoss <29103029+Stedoss@users.noreply.github.com> Date: Tue, 28 Jul 2026 09:04:20 +0000 Subject: [PATCH 4/4] Formatting --- src/mission-control-client/src/utils/dateUtils.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mission-control-client/src/utils/dateUtils.test.ts b/src/mission-control-client/src/utils/dateUtils.test.ts index 3bd83cc..4b97057 100644 --- a/src/mission-control-client/src/utils/dateUtils.test.ts +++ b/src/mission-control-client/src/utils/dateUtils.test.ts @@ -21,7 +21,9 @@ describe('dateUtils', () => { const date = toReadableDateTime('2026-07-27T23:27:22.1976394+00:00'); // Date invariants are annoying, test that we are getting back the locale in this case - expect(date).toBe(new Date('2026-07-27T23:27:22.1976394+00:00').toLocaleString()); + expect(date).toBe( + new Date('2026-07-27T23:27:22.1976394+00:00').toLocaleString(), + ); }); }); }); -- 2.54.0