Skip to content

Commit

Permalink
test(query-engine): Fix PlanetScale test, #4485
Browse files Browse the repository at this point in the history
  • Loading branch information
jkomyno committed Jun 6, 2024
1 parent 8a7b4f7 commit e7ad242
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ mod update_many {
}

// "An updateMany mutation" should "correctly apply all number operations for Int"
#[connector_test(exclude(Vitess("planetscale.js", "planetscale.js.wasm"), CockroachDb))]
#[connector_test(exclude(CockroachDb))]
async fn apply_number_ops_for_int(runner: Runner) -> TestResult<()> {
create_row(&runner, r#"{ id: 1, optStr: "str1" }"#).await?;
create_row(&runner, r#"{ id: 2, optStr: "str2", optInt: 2 }"#).await?;
Expand Down Expand Up @@ -240,7 +240,7 @@ mod update_many {
}

// "An updateMany mutation" should "correctly apply all number operations for Float"
#[connector_test(exclude(Vitess("planetscale.js", "planetscale.js.wasm")))]
#[connector_test]
async fn apply_number_ops_for_float(runner: Runner) -> TestResult<()> {
create_row(&runner, r#"{ id: 1, optStr: "str1" }"#).await?;
create_row(&runner, r#"{ id: 2, optStr: "str2", optFloat: 2 }"#).await?;
Expand Down Expand Up @@ -297,10 +297,10 @@ mod update_many {
let count = &res["data"]["updateManyTestModel"]["count"];

// MySql does not count incrementing a null so the count is different
if !matches!(runner.connector_version(), ConnectorVersion::MySql(_)) {
// On PlanetScale, this fails with:
// left: Number(2)
// right: 3
if !matches!(
runner.connector_version(),
ConnectorVersion::MySql(_) | ConnectorVersion::Vitess(_)
) {
assert_eq!(count, 3);
}

Expand Down

0 comments on commit e7ad242

Please sign in to comment.