-
Notifications
You must be signed in to change notification settings - Fork 219
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
181 additions
and
11 deletions.
There are no files selected for viewing
4 changes: 4 additions & 0 deletions
4
prisma-fmt/tests/text_document_completion/scenarios/default_map_mssql_multifile/Test.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
model Test { | ||
id Int @id | ||
name String @default(<|>) | ||
} |
4 changes: 4 additions & 0 deletions
4
prisma-fmt/tests/text_document_completion/scenarios/default_map_mssql_multifile/TestB.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
model TestB { | ||
id String @id | ||
name Int | ||
} |
4 changes: 4 additions & 0 deletions
4
...ma-fmt/tests/text_document_completion/scenarios/default_map_mssql_multifile/config.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
datasource db { | ||
provider = "sqlserver" | ||
url = env("DATABASE_URL") | ||
} |
9 changes: 9 additions & 0 deletions
9
prisma-fmt/tests/text_document_completion/scenarios/default_map_mssql_multifile/result.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"isIncomplete": false, | ||
"items": [ | ||
{ | ||
"label": "map: ", | ||
"kind": 10 | ||
} | ||
] | ||
} |
6 changes: 6 additions & 0 deletions
6
...sts/text_document_completion/scenarios/extended_indexes_types_postgres_multifile/A.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
model A { | ||
id Int @id | ||
val String | ||
@@index([val], type: <|>) | ||
} |
4 changes: 4 additions & 0 deletions
4
...document_completion/scenarios/extended_indexes_types_postgres_multifile/datasource.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
datasource db { | ||
provider = "postgres" | ||
url = env("DATABASE_URL") | ||
} |
3 changes: 3 additions & 0 deletions
3
..._document_completion/scenarios/extended_indexes_types_postgres_multifile/generator.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
generator js { | ||
provider = "prisma-client-js" | ||
} |
35 changes: 35 additions & 0 deletions
35
.../text_document_completion/scenarios/extended_indexes_types_postgres_multifile/result.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
"isIncomplete": false, | ||
"items": [ | ||
{ | ||
"label": "BTree", | ||
"kind": 13, | ||
"detail": "Can handle equality and range queries on data that can be sorted into some ordering (default)." | ||
}, | ||
{ | ||
"label": "Hash", | ||
"kind": 13, | ||
"detail": "Can handle simple equality queries, but no ordering. Faster than BTree, if ordering is not needed." | ||
}, | ||
{ | ||
"label": "Gist", | ||
"kind": 13, | ||
"detail": "Generalized Search Tree. A framework for building specialized indices for custom data types." | ||
}, | ||
{ | ||
"label": "Gin", | ||
"kind": 13, | ||
"detail": "Generalized Inverted Index. Useful for indexing composite items, such as arrays or text." | ||
}, | ||
{ | ||
"label": "SpGist", | ||
"kind": 13, | ||
"detail": "Space-partitioned Generalized Search Tree. For implenting a wide range of different non-balanced data structures." | ||
}, | ||
{ | ||
"label": "Brin", | ||
"kind": 13, | ||
"detail": "Block Range Index. If the data has some natural correlation with their physical location within the table, can compress very large amount of data into a small space." | ||
} | ||
] | ||
} |
4 changes: 4 additions & 0 deletions
4
...tests/text_document_completion/scenarios/no_default_map_on_postgres_multifile/Test.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
model Test { | ||
id Int @id | ||
name String @default(<|>) | ||
} |
4 changes: 4 additions & 0 deletions
4
...ests/text_document_completion/scenarios/no_default_map_on_postgres_multifile/TestB.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
model TestB { | ||
id String @id | ||
name Int | ||
} |
4 changes: 4 additions & 0 deletions
4
...sts/text_document_completion/scenarios/no_default_map_on_postgres_multifile/config.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
datasource db { | ||
provider = "postgresql" | ||
url = env("DATABASE_URL") | ||
} |
4 changes: 4 additions & 0 deletions
4
...tests/text_document_completion/scenarios/no_default_map_on_postgres_multifile/result.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"isIncomplete": false, | ||
"items": [] | ||
} |
5 changes: 5 additions & 0 deletions
5
...-fmt/tests/text_document_completion/scenarios/referential_actions_multifile/config.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
datasource db { | ||
provider = "mysql" | ||
url = env("DATABASE_URL") | ||
relationMode = "prisma" | ||
} |
11 changes: 11 additions & 0 deletions
11
...-fmt/tests/text_document_completion/scenarios/referential_actions_multifile/models.prisma
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
model Post { | ||
id Int @id @default(autoincrement()) | ||
title String | ||
author User @relation(fields: [authorId], references: [id], onDelete: <|>) | ||
authorId Int | ||
} | ||
|
||
model User { | ||
id Int @id @default(autoincrement()) | ||
posts Post[] | ||
} |
25 changes: 25 additions & 0 deletions
25
...ma-fmt/tests/text_document_completion/scenarios/referential_actions_multifile/result.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"isIncomplete": false, | ||
"items": [ | ||
{ | ||
"label": "Cascade", | ||
"kind": 13, | ||
"detail": "Delete the child records when the parent record is deleted." | ||
}, | ||
{ | ||
"label": "Restrict", | ||
"kind": 13, | ||
"detail": "Prevent deleting a parent record as long as it is referenced." | ||
}, | ||
{ | ||
"label": "NoAction", | ||
"kind": 13, | ||
"detail": "Prevent deleting a parent record as long as it is referenced." | ||
}, | ||
{ | ||
"label": "SetNull", | ||
"kind": 13, | ||
"detail": "Set the referencing fields to NULL when the referenced record is deleted." | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters