Skip to content

Commit b5b6c13

Browse files
Merge branch 'main' into rachel/test-sourcepoint-australia-migration
2 parents ab0a601 + 661e150 commit b5b6c13

32 files changed

+460
-283
lines changed

.github/workflows/ab-testing-ui.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
run:
1515
working-directory: ab-testing/frontend
1616
steps:
17-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@v5
1818

1919
# https://github.com/denoland/setup-deno#latest-stable-for-a-major
2020
- uses: denoland/setup-deno@v1
@@ -41,7 +41,7 @@ jobs:
4141

4242
steps:
4343
- name: Checkout
44-
uses: actions/checkout@v4.2.2
44+
uses: actions/checkout@v5
4545
with:
4646
fetch-depth: 0
4747
persist-credentials: false
@@ -50,7 +50,7 @@ jobs:
5050
uses: ./.github/actions/setup-node-env
5151

5252
- name: Fetch build
53-
uses: actions/download-artifact@v4.3.0
53+
uses: actions/download-artifact@v5.0.0
5454
with:
5555
name: ui-build
5656
path: output/ab-tests.html

.github/workflows/chromatic-label-helper.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
if: ${{ github.event.pull_request.draft == false}}
2020

2121
steps:
22-
- uses: actions/github-script@v7
22+
- uses: actions/github-script@v8
2323
with:
2424
script: |
2525
const labels = await github.rest.issues

.github/workflows/dcr-chromatic.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
pull-requests: write
5555
steps:
5656
- name: Remove run_chromatic label
57-
uses: actions/github-script@v7
57+
uses: actions/github-script@v8
5858
with:
5959
script: |
6060
await github.rest.issues.removeLabel({

.github/workflows/labeler.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
pull-requests: write
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/labeler@v5
12+
- uses: actions/labeler@v6
1313
with:
1414
repo-token: '${{ secrets.GITHUB_TOKEN }}'
1515
sync-labels: true # remove redundant labels after a change

ab-testing/abTest.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ export const ABTests: ABTest[] = [
3131
type: 'client',
3232
audienceSize: 10 / 100,
3333
groups: ['control', 'variant'],
34+
shouldForceMetricsCollection: true,
3435
},
3536
{
3637
name: 'commercial-server-side-test',
@@ -42,6 +43,7 @@ export const ABTests: ABTest[] = [
4243
type: 'server',
4344
audienceSize: 10 / 100,
4445
groups: ['control', 'variant'],
46+
shouldForceMetricsCollection: true,
4547
},
4648
{
4749
name: 'commercial-large-overlap-test',
@@ -57,5 +59,6 @@ export const ABTests: ABTest[] = [
5759
audienceSize: 50 / 100,
5860
groups: ['control', 'variant'],
5961
audienceSpace: 'B',
62+
shouldForceMetricsCollection: true,
6063
},
6164
];

ab-testing/index.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// @ts-ignore - extension is required to import this as a package in DCR
2+
import { ABTests } from './abTest.ts';
3+
4+
export { ABTests };

ab-testing/package.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"name": "@guardian/ab-testing",
3+
"version": "1.0.0",
4+
"description": "A/B test definitions and configuration",
5+
"main": "index.ts",
6+
"type": "module"
7+
}

ab-testing/types.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,10 @@ type ABTest = {
3737
audienceSpace?: 'A' | 'B' | 'C';
3838
/** Test group definition */
3939
groups: string[];
40+
/** Bypasses sampling to force metrics collection for this test
41+
* See DCR Metrics component for end usage
42+
*/
43+
shouldForceMetricsCollection?: boolean;
4044
};
4145

4246
export type { ABTest, FastlyTestParams, AudienceSpace, AllSpace };

dotcom-rendering/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"@emotion/react": "11.14.0",
2828
"@emotion/server": "11.11.0",
2929
"@guardian/ab-core": "8.0.0",
30+
"@guardian/ab-testing": "workspace:ab-testing",
3031
"@guardian/braze-components": "22.2.0",
3132
"@guardian/bridget": "8.7.0",
3233
"@guardian/browserslist-config": "6.1.0",
@@ -46,7 +47,7 @@
4647
"@guardian/support-dotcom-components": "7.7.0",
4748
"@guardian/tsconfig": "0.2.0",
4849
"@playwright/test": "1.52.0",
49-
"@sentry/browser": "10.3.0",
50+
"@sentry/browser": "10.10.0",
5051
"@storybook/addon-essentials": "8.6.14",
5152
"@storybook/addon-interactions": "8.6.14",
5253
"@storybook/addon-webpack5-compiler-swc": "3.0.0",

dotcom-rendering/src/components/Avatar.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ const decideImageWidths = (
8888
];
8989

9090
case 'large':
91+
case 'xlarge':
9192
return [
9293
{
9394
breakpoint: breakpoints.mobile,

0 commit comments

Comments
 (0)