All files / src/Projection/migrations 1695899010515-pool-delisted-table.ts

60% Statements 3/5
100% Branches 0/0
0% Functions 0/2
60% Lines 3/5

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20  35x   35x 35x                              
import { MigrationInterface, QueryRunner } from 'typeorm';
import { PoolDelistedEntity } from '@cardano-sdk/projection-typeorm';
 
export class PoolDelistedTableMigration1695899010515 implements MigrationInterface {
  static entity = PoolDelistedEntity;
 
  public async up(queryRunner: QueryRunner): Promise<void> {
    await queryRunner.query(`CREATE TABLE "pool_delisted"
                             (
 
                                 "stake_pool_id" character(56) NOT NULL,
                                 CONSTRAINT "PK_pool_delisted_stake_pool_id" PRIMARY KEY ("stake_pool_id")
                             )`);
  }
 
  public async down(queryRunner: QueryRunner): Promise<void> {
    await queryRunner.query('DROP TABLE "pool_delisted"');
  }
}