Run the formatter over the shard-naming change
Build and test / android-image (push) Canceled after 1m38s
Build and test / Android (aarch64) (push) Canceled after 0s
Build and test / Desktop (Linux) (push) Canceled after 1m34s
Build and test / Layer separation (push) Canceled after 0s
🐳 Android image / Build and push (push) Canceled after 1m38s
Traceability / Requirement traces (push) Successful in 1m2s
Build and test / android-image (push) Canceled after 1m38s
Build and test / Android (aarch64) (push) Canceled after 0s
Build and test / Desktop (Linux) (push) Canceled after 1m34s
Build and test / Layer separation (push) Canceled after 0s
🐳 Android image / Build and push (push) Canceled after 1m38s
Traceability / Requirement traces (push) Successful in 1m2s
`cargo fmt --all -- --check` is a CI gate and 9a51cc8 landed two files past
it, so the build has been red on master since regardless of what came after.
Whitespace only — a wrapped `Ok(...)` and two `assert_eq!`s split across
lines. No logic is touched and the tests are unchanged.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -633,9 +633,11 @@ fn mint_client_id(conn: &Connection) -> Result<String, ThumbError> {
|
|||||||
ON CONFLICT(key) DO NOTHING",
|
ON CONFLICT(key) DO NOTHING",
|
||||||
[],
|
[],
|
||||||
)?;
|
)?;
|
||||||
Ok(conn.query_row("SELECT value FROM meta WHERE key = 'client_id'", [], |r| {
|
Ok(
|
||||||
r.get(0)
|
conn.query_row("SELECT value FROM meta WHERE key = 'client_id'", [], |r| {
|
||||||
})?)
|
r.get(0)
|
||||||
|
})?,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
const SHARD_SCHEMA: &str = r#"
|
const SHARD_SCHEMA: &str = r#"
|
||||||
|
|||||||
@@ -404,8 +404,14 @@ mod tests {
|
|||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn shard_names_round_trip() {
|
fn shard_names_round_trip() {
|
||||||
assert_eq!(shard_name("a1b2c3d4e5f6", 0), "shard-a1b2c3d4e5f6-0000.sqlite");
|
assert_eq!(
|
||||||
assert_eq!(shard_name("a1b2c3d4e5f6", 42), "shard-a1b2c3d4e5f6-0042.sqlite");
|
shard_name("a1b2c3d4e5f6", 0),
|
||||||
|
"shard-a1b2c3d4e5f6-0000.sqlite"
|
||||||
|
);
|
||||||
|
assert_eq!(
|
||||||
|
shard_name("a1b2c3d4e5f6", 42),
|
||||||
|
"shard-a1b2c3d4e5f6-0042.sqlite"
|
||||||
|
);
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
parse_shard(&shard_name("a1b2c3d4e5f6", 7)),
|
parse_shard(&shard_name("a1b2c3d4e5f6", 7)),
|
||||||
Some(("a1b2c3d4e5f6", 7))
|
Some(("a1b2c3d4e5f6", 7))
|
||||||
|
|||||||
Reference in New Issue
Block a user