fix(test): robustify integration tests #58

Closed
opened 2025-08-12 09:34:16 +00:00 by chartgerink · 0 comments
Owner

Currently, integration tests can rely on synchronous state evaluations. These include exact number of objects returned. This is not robust and leads to errors that are technically not errors.

In order to make those tests more robust, we can reduce reliance on synchronous state in asynchronous functions. Or we can dynamically evaluate state right before the evaluations take place, but that may be subject to race conditions.

In general, every integration test needs to be reviewed for this.

  • affiliation-crud.rs
  • authorships-crud.rs
  • common.rs
  • email-verification.rs
  • institutions-crud.rs
  • integration-auth.rs
  • oidc-integration.rs
  • oidc-redis.rs
  • outputs-crud.rs
  • reset-password.rs
  • ror-integration.rs
  • upload-avatar.rs
  • upload-integration.rs
  • users-crud.rs
  • versions-crud.rs
Currently, integration tests can rely on synchronous state evaluations. These include exact number of objects returned. This is not robust and leads to errors that are technically not errors. In order to make those tests more robust, we can reduce reliance on synchronous state in asynchronous functions. Or we can dynamically evaluate state right before the evaluations take place, but that may be subject to race conditions. In general, every integration test needs to be reviewed for this. - [x] affiliation-crud.rs - [x] authorships-crud.rs - [x] common.rs - [x] email-verification.rs - [x] institutions-crud.rs - [x] integration-auth.rs - [x] oidc-integration.rs - [x] oidc-redis.rs - [x] outputs-crud.rs - [x] reset-password.rs - [x] ror-integration.rs - [x] upload-avatar.rs - [x] upload-integration.rs - [x] users-crud.rs - [x] versions-crud.rs
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: libscie/researchequals-api#58
No description provided.