From f35e212dabaff4d034156eafefcc052bafd7286d Mon Sep 17 00:00:00 2001 From: Kononnable Date: Thu, 19 Mar 2020 23:26:22 +0100 Subject: [PATCH] test for generating column comment(#93,#260) --- .../github-issues/93/entity/Post.ts | 22 +++++++++++++++++++ test/integration/runTestsFromPath.test.ts | 5 +++++ 2 files changed, 27 insertions(+) create mode 100644 test/integration/github-issues/93/entity/Post.ts diff --git a/test/integration/github-issues/93/entity/Post.ts b/test/integration/github-issues/93/entity/Post.ts new file mode 100644 index 0000000..9796313 --- /dev/null +++ b/test/integration/github-issues/93/entity/Post.ts @@ -0,0 +1,22 @@ +import { + Index, + Entity, + PrimaryColumn, + Column, + OneToOne, + OneToMany, + ManyToOne, + JoinColumn +} from "typeorm"; + +@Entity("Post") +export class Post { + @Column("integer", { + primary: true, + name: "id" + }) + id: number; + + @Column({ comment: "comment" }) + body: string; +} diff --git a/test/integration/runTestsFromPath.test.ts b/test/integration/runTestsFromPath.test.ts index 0381109..2462b5d 100644 --- a/test/integration/runTestsFromPath.test.ts +++ b/test/integration/runTestsFromPath.test.ts @@ -128,6 +128,11 @@ function runTestForMultipleDrivers( dbDriver ) ); + case "93": + return dbDrivers.filter( + dbDriver => + ["mysql", "mariadb"].includes(dbDriver) // Only db engines supported by typeorm at the time of writing + ); case "144": return dbDrivers.filter(dbDriver => ["mysql", "mariadb"].includes(dbDriver)