Skip to content

Commit 25055bb

Browse files
committed
test(integration): update offline error expectations
1 parent 21f2971 commit 25055bb

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

test/integration.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -437,22 +437,22 @@ int test_offline_error(const char *db_path) {
437437
char verify_sql[1024];
438438
snprintf(verify_sql, sizeof(verify_sql),
439439
"SELECT json_extract('%s', '$.errors[0].status');", errmsg);
440-
rc = db_expect_str(db, verify_sql, "500");
440+
rc = db_expect_str(db, verify_sql, "503");
441441
if (rc != SQLITE_OK) { printf("Offline error: unexpected status in: %s\n", errmsg); sqlite3_free(errmsg); goto abort_test; }
442442

443443
snprintf(verify_sql, sizeof(verify_sql),
444444
"SELECT json_extract('%s', '$.errors[0].code');", errmsg);
445-
rc = db_expect_str(db, verify_sql, "internal_server_error");
445+
rc = db_expect_str(db, verify_sql, "database_paused");
446446
if (rc != SQLITE_OK) { printf("Offline error: unexpected code in: %s\n", errmsg); sqlite3_free(errmsg); goto abort_test; }
447447

448448
snprintf(verify_sql, sizeof(verify_sql),
449449
"SELECT json_extract('%s', '$.errors[0].title');", errmsg);
450-
rc = db_expect_str(db, verify_sql, "Internal Server Error");
450+
rc = db_expect_str(db, verify_sql, "Database paused");
451451
if (rc != SQLITE_OK) { printf("Offline error: unexpected title in: %s\n", errmsg); sqlite3_free(errmsg); goto abort_test; }
452452

453453
snprintf(verify_sql, sizeof(verify_sql),
454454
"SELECT json_extract('%s', '$.errors[0].detail');", errmsg);
455-
rc = db_expect_str(db, verify_sql, "failed to resolve token data: failed to resolve db user for api key: db: connect sqlitecloud failed after 3 attempts: Your free node has been paused due to inactivity. To resume usage, please restart your node from your dashboard: https://dashboard.sqlitecloud.io");
455+
rc = db_expect_str(db, verify_sql, "database is paused due to inactivity; restart the node from the SQLite Cloud dashboard: ERROR: Your free node has been paused due to inactivity. To resume usage, please restart your node from your dashboard: https://dashboard.sqlitecloud.io (10010 - -1)");
456456
if (rc != SQLITE_OK) { printf("Offline error: unexpected detail in: %s\n", errmsg); sqlite3_free(errmsg); goto abort_test; }
457457

458458
sqlite3_free(errmsg);

0 commit comments

Comments
 (0)