From 7320bfae295254d9b1fefc5030ff162143c7be7b Mon Sep 17 00:00:00 2001 From: Serhii Tatarintsev Date: Mon, 3 Jun 2024 11:31:17 +0200 Subject: [PATCH] psl: Make `prismaSchemaFolder` feature public (#4896) * psl: Make `prismaSchemaFolder` feature public * Fix tests * Update snapshots --- psl/psl-core/src/common/preview_features.rs | 3 ++- psl/psl/tests/config/generators.rs | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/psl/psl-core/src/common/preview_features.rs b/psl/psl-core/src/common/preview_features.rs index 9ad86929a34a..cadaa636395e 100644 --- a/psl/psl-core/src/common/preview_features.rs +++ b/psl/psl-core/src/common/preview_features.rs @@ -98,6 +98,7 @@ pub const ALL_PREVIEW_FEATURES: FeatureMap = FeatureMap { | Views | RelationJoins | OmitApi + | PrismaSchemaFolder }), deprecated: enumflags2::make_bitflags!(PreviewFeature::{ AtomicNumberOperations @@ -132,7 +133,7 @@ pub const ALL_PREVIEW_FEATURES: FeatureMap = FeatureMap { | TransactionApi | UncheckedScalarInputs }), - hidden: enumflags2::make_bitflags!(PreviewFeature::{PrismaSchemaFolder | ReactNative}), + hidden: enumflags2::make_bitflags!(PreviewFeature::{ReactNative}), }; #[derive(Debug)] diff --git a/psl/psl/tests/config/generators.rs b/psl/psl/tests/config/generators.rs index 3bba14a7b265..273de14c7443 100644 --- a/psl/psl/tests/config/generators.rs +++ b/psl/psl/tests/config/generators.rs @@ -258,7 +258,7 @@ fn nice_error_for_unknown_generator_preview_feature() { .unwrap_err(); let expectation = expect![[r#" - error: The preview feature "foo" is not known. Expected one of: deno, driverAdapters, fullTextIndex, fullTextSearch, metrics, multiSchema, nativeDistinct, postgresqlExtensions, tracing, views, relationJoins, omitApi + error: The preview feature "foo" is not known. Expected one of: deno, driverAdapters, fullTextIndex, fullTextSearch, metrics, multiSchema, nativeDistinct, postgresqlExtensions, tracing, views, relationJoins, prismaSchemaFolder, omitApi --> schema.prisma:3  |   2 |  provider = "prisma-client-js"