fix(data): avoid duplicate user group migration version

This commit is contained in:
Entropy.Xu
2026-05-09 22:26:31 +08:00
parent a68c690874
commit 121bdbd614
5 changed files with 7 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ use tracing::info;
// Generated by build.rs from schema/bootstrap/postgres. // Generated by build.rs from schema/bootstrap/postgres.
pub(crate) static EMPTY_DATABASE_SNAPSHOT_SQL: &str = pub(crate) static EMPTY_DATABASE_SNAPSHOT_SQL: &str =
include_str!(concat!(env!("OUT_DIR"), "/empty_database_snapshot.sql")); include_str!(concat!(env!("OUT_DIR"), "/empty_database_snapshot.sql"));
pub(crate) const EMPTY_DATABASE_SNAPSHOT_CUTOFF_VERSION: i64 = 20260509000000; pub(crate) const EMPTY_DATABASE_SNAPSHOT_CUTOFF_VERSION: i64 = 20260509120000;
const PUBLIC_BASE_TABLE_COUNT_SQL: &str = r#" const PUBLIC_BASE_TABLE_COUNT_SQL: &str = r#"
SELECT COUNT(*)::BIGINT SELECT COUNT(*)::BIGINT

View File

@@ -295,6 +295,7 @@ fn empty_database_snapshot_covers_current_cutoff_versions() {
20260507120000, 20260507120000,
20260508000000, 20260508000000,
20260509000000, 20260509000000,
20260509120000,
] ]
); );
} }
@@ -518,7 +519,8 @@ fn mysql_and_sqlite_migrations_include_enabled_incrementals() {
20260403000000, 20260403000000,
20260507120000, 20260507120000,
20260508000000, 20260508000000,
20260509000000 20260509000000,
20260509120000
] ]
); );
assert_eq!( assert_eq!(
@@ -527,7 +529,8 @@ fn mysql_and_sqlite_migrations_include_enabled_incrementals() {
20260403000000, 20260403000000,
20260507120000, 20260507120000,
20260508000000, 20260508000000,
20260509000000 20260509000000,
20260509120000
] ]
); );
} }
@@ -1034,6 +1037,7 @@ fn pending_migrations_from_applied_skips_versions_already_applied() {
20260507120000, 20260507120000,
20260508000000, 20260508000000,
20260509000000, 20260509000000,
20260509120000,
] ]
); );
} }