Skip to content

Commit

Permalink
Update gmail test configuration
Browse files Browse the repository at this point in the history
Update gmail test configuration
  • Loading branch information
pablonyx authored Dec 14, 2024
2 parents 73a86b9 + e9b41bd commit 1eeab8c
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 27 deletions.
26 changes: 12 additions & 14 deletions backend/tests/daily/connectors/gmail/test_gmail_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,26 @@

"""
This thread was 4 emails long:
admin@danswer-test.com -> [email protected] (conaining test_user_1 and test_user_2)
[email protected] -> admin@danswer-test.com
admin@danswer-test.com -> [email protected] + BCC: [email protected]
[email protected] -> admin@danswer-test.com
admin@onyx-test.com -> [email protected] (conaining test_user_1 and test_user_2)
[email protected] -> admin@onyx-test.com
admin@onyx-test.com -> [email protected] + BCC: [email protected]
[email protected] -> admin@onyx-test.com
"""
_THREAD_1_BY_ID: dict[str, dict[str, Any]] = {
"192edefb315737c3": {
"email": "admin@danswer-test.com",
"email": "admin@onyx-test.com",
"sections_count": 4,
"primary_owners": set(
[
"admin@danswer-test.com",
"admin@onyx-test.com",
"[email protected]",
"[email protected]",
]
),
"secondary_owners": set(
[
"[email protected]",
"admin@danswer-test.com",
"admin@onyx-test.com",
"[email protected]",
"[email protected]",
]
Expand All @@ -41,26 +41,24 @@
"192edf020d2f5def": {
"email": "[email protected]",
"sections_count": 2,
"primary_owners": set(["[email protected]", "[email protected]"]),
"secondary_owners": set(
["[email protected]", "[email protected]"]
),
"primary_owners": set(["[email protected]", "[email protected]"]),
"secondary_owners": set(["[email protected]", "[email protected]"]),
},
"192edf020ae90aab": {
"email": "[email protected]",
"sections_count": 2,
"primary_owners": set(["admin@danswer-test.com"]),
"primary_owners": set(["admin@onyx-test.com"]),
"secondary_owners": set(
["[email protected]", "[email protected]"]
),
},
"192edf18316015fa": {
"email": "[email protected]",
"sections_count": 2,
"primary_owners": set(["admin@danswer-test.com", "[email protected]"]),
"primary_owners": set(["admin@onyx-test.com", "[email protected]"]),
"secondary_owners": set(
[
"admin@danswer-test.com",
"admin@onyx-test.com",
"[email protected]",
"[email protected]",
]
Expand Down
4 changes: 2 additions & 2 deletions backend/tests/daily/connectors/google_drive/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@


_USER_TO_OAUTH_CREDENTIALS_MAP = {
"admin@danswer-test.com": "GOOGLE_DRIVE_OAUTH_CREDENTIALS_JSON_STR",
"admin@onyx-test.com": "GOOGLE_DRIVE_OAUTH_CREDENTIALS_JSON_STR",
"[email protected]": "GOOGLE_DRIVE_OAUTH_CREDENTIALS_JSON_STR_TEST_USER_1",
}

_USER_TO_SERVICE_ACCOUNT_CREDENTIALS_MAP = {
"admin@danswer-test.com": "GOOGLE_DRIVE_SERVICE_ACCOUNT_JSON_STR",
"admin@onyx-test.com": "GOOGLE_DRIVE_SERVICE_ACCOUNT_JSON_STR",
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"https://drive.google.com/drive/u/5/folders/1loe6XJ-pJxu9YYPv7cF3Hmz296VNzA33"
)

ADMIN_EMAIL = "admin@danswer-test.com"
ADMIN_EMAIL = "admin@onyx-test.com"
TEST_USER_1_EMAIL = "[email protected]"
TEST_USER_2_EMAIL = "[email protected]"
TEST_USER_3_EMAIL = "[email protected]"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def test_slack_permission_sync(

# Creating an admin user (first user created is automatically an admin)
admin_user: DATestUser = UserManager.create(
email="admin@danswer-test.com",
email="admin@onyx-test.com",
)

# Creating a non-admin user
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def test_slack_prune(

# Creating an admin user (first user created is automatically an admin)
admin_user: DATestUser = UserManager.create(
email="admin@danswer-test.com",
email="admin@onyx-test.com",
)

# Creating a non-admin user
Expand Down
16 changes: 8 additions & 8 deletions backend/tests/unit/onyx/connectors/gmail/thread.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
},
{
"name": "From",
"value": "Test Admin Admin <admin@danswer-test.com>"
"value": "Test Admin Admin <admin@onyx-test.com>"
},
{
"name": "To",
Expand Down Expand Up @@ -56,7 +56,7 @@
"headers": [
{
"name": "Delivered-To",
"value": "admin@danswer-test.com"
"value": "admin@onyx-test.com"
},
{
"name": "Received",
Expand Down Expand Up @@ -84,7 +84,7 @@
},
{
"name": "Received",
"value": "from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id a1e0cc1a2514c-855dae589a1sor1192309241.6.2024.11.02.10.33.34 for <admin@danswer-test.com> (Google Transport Security); Sat, 02 Nov 2024 10:33:34 -0700 (PDT)"
"value": "from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id a1e0cc1a2514c-855dae589a1sor1192309241.6.2024.11.02.10.33.34 for <admin@onyx-test.com> (Google Transport Security); Sat, 02 Nov 2024 10:33:34 -0700 (PDT)"
},
{
"name": "Received-SPF",
Expand Down Expand Up @@ -144,7 +144,7 @@
},
{
"name": "To",
"value": "Test Admin Admin <admin@danswer-test.com>"
"value": "Test Admin Admin <admin@onyx-test.com>"
},
{
"name": "Content-Type",
Expand Down Expand Up @@ -201,7 +201,7 @@
},
{
"name": "From",
"value": "Test Admin Admin <admin@danswer-test.com>"
"value": "Test Admin Admin <admin@onyx-test.com>"
},
{
"name": "To",
Expand Down Expand Up @@ -234,7 +234,7 @@
"headers": [
{
"name": "Delivered-To",
"value": "admin@danswer-test.com"
"value": "admin@onyx-test.com"
},
{
"name": "Received",
Expand Down Expand Up @@ -262,7 +262,7 @@
},
{
"name": "Received",
"value": "from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id 71dfb90a1353d-5106f3f9037sor1051490e0c.7.2024.11.02.10.35.06 for <admin@danswer-test.com> (Google Transport Security); Sat, 02 Nov 2024 10:35:06 -0700 (PDT)"
"value": "from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id 71dfb90a1353d-5106f3f9037sor1051490e0c.7.2024.11.02.10.35.06 for <admin@onyx-test.com> (Google Transport Security); Sat, 02 Nov 2024 10:35:06 -0700 (PDT)"
},
{
"name": "Received-SPF",
Expand Down Expand Up @@ -322,7 +322,7 @@
},
{
"name": "To",
"value": "Test Admin Admin <admin@danswer-test.com>"
"value": "Test Admin Admin <admin@onyx-test.com>"
},
{
"name": "Content-Type",
Expand Down

0 comments on commit 1eeab8c

Please sign in to comment.