canonical / canonical/authd

Flaky test TestGdmModel/New_password_cannot_change_because_not_respecting_rules_with_preset_PAM_user_and_server_side_broker_and_authMode_selection

Open
#1,029 3 comments 0 reactions 1 assignee Claimed by @3v1n0 View on GitHub
Dominant language
Go
Stars
308
Forks
41
Avg merge
2d 4h
Merged PRs (30d)
58

Description

https://github.com/ubuntu/authd/actions/runs/16645594210/job/47105388753?pr=1027#step:3:41626

```
2025-07-31T09:56:36.8883562Z gdmmodel_test.go:2671:
2025-07-31T09:56:36.8884066Z Error Trace: /home/runner/work/authd/authd/tmp.psCAUeCiz0/source/obj-x86_64-linux-gnu/src/github.com/ubuntu/authd/pam/internal/gdm_test/gdm_utils.go:22
2025-07-31T09:56:36.8884542Z /home/runner/work/authd/authd/tmp.psCAUeCiz0/source/obj-x86_64-linux-gnu/src/github.com/ubuntu/authd/pam/internal/adapter/gdmmodel_test.go:2671
2025-07-31T09:56:36.8884712Z Error: Not equal:
2025-07-31T09:56:36.8885517Z expected: "[\n {\n \"access\": \"retry\",\n \"msg\": \"The password is shorter than 8 characters\"\n },\n {\n \"access\": \"retry\",\n \"msg\": \"The password fails the dictionary check - it is based on a dictionary word\"\n },\n {\n \"access\": \"granted\",\n \"msg\": \"Hi GDM, it's a pleasure to change your password!\"\n }\n]"
2025-07-31T09:56:36.8886247Z actual : "[\n {\n \"access\": \"retry\",\n \"msg\": \"The password fails the dictionary check - it is based on a dictionary word\"\n },\n {\n \"access\": \"retry\",\n \"msg\": \"The password is shorter than 8 characters\"\n },\n {\n \"access\": \"granted\",\n \"msg\": \"Hi GDM, it's a pleasure to change your password!\"\n }\n]"
2025-07-31T09:56:36.8886368Z
2025-07-31T09:56:36.8886434Z Diff:
2025-07-31T09:56:36.8886518Z --- Expected
2025-07-31T09:56:36.8886685Z +++ Actual
2025-07-31T09:56:36.8886768Z @@ -3,3 +3,3 @@
2025-07-31T09:56:36.8886852Z "access": "retry",
2025-07-31T09:56:36.8886985Z - "msg": "The password is shorter than 8 characters"
2025-07-31T09:56:36.8887263Z + "msg": "The password fails the dictionary check - it is based on a dictionary word"
2025-07-31T09:56:36.8887331Z },
2025-07-31T09:56:36.8887406Z @@ -7,3 +7,3 @@
2025-07-31T09:56:36.8887484Z "access": "retry",
2025-07-31T09:56:36.8887692Z - "msg": "The password fails the dictionary check - it is based on a dictionary word"
2025-07-31T09:56:36.8887810Z + "msg": "The password is shorter than 8 characters"
2025-07-31T09:56:36.8887875Z },
2025-07-31T09:56:36.8888305Z Test: TestGdmModel/New_password_cannot_change_because_not_respecting_rules_with_preset_PAM_user_and_server_side_broker_and_authMode_selection
```

The test case is defined [here](https://github.com/ubuntu/authd/blob/e1d3766599c9c76f957d631d866ca211b32a3fc7/pam/internal/adapter/gdmmodel_test.go#L491-L556).

It looks like the events that are being sent are not handled in order.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.