Skip to content

Commit b7fc500

Browse files
authored
adjusting some migration tests so that baselines dont depend on the product version (#34977)
1 parent 919e5dd commit b7fc500

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

test/EFCore.SqlServer.FunctionalTests/Migrations/MigrationsInfrastructureSqlServerTest.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -755,7 +755,7 @@ FROM [__EFMigrationsHistory]
755755
ORDER BY [MigrationId];
756756
757757
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
758-
VALUES (N'00000000000000_Empty', N'9.0.0');
758+
VALUES (N'00000000000000_Empty', N'7.0.0-test');
759759
760760
--Before
761761
@@ -798,18 +798,18 @@ CONSTRAINT [PK_Blogs] PRIMARY KEY ([Id])
798798
END
799799
800800
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
801-
VALUES (N'00000000000001_Migration1', N'9.0.0');
801+
VALUES (N'00000000000001_Migration1', N'7.0.0-test');
802802
803803
--After
804804
805805
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
806-
VALUES (N'00000000000002_Migration2', N'9.0.0');
806+
VALUES (N'00000000000002_Migration2', N'7.0.0-test');
807807
808808
DECLARE @result int;
809809
EXEC @result = sp_releaseapplock @Resource = '__EFMigrationsLock', @LockOwner = 'Session';
810810
SELECT @result
811811
""",
812-
Fixture.TestSqlLoggerFactory.Sql,
812+
Fixture.TestSqlLoggerFactory.Sql.Replace(ProductInfo.GetVersion(), "7.0.0-test"),
813813
ignoreLineEndingDifferences: true);
814814
}
815815

@@ -867,7 +867,7 @@ FROM [__EFMigrationsHistory]
867867
ORDER BY [MigrationId];
868868
869869
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
870-
VALUES (N'00000000000000_Empty', N'9.0.0');
870+
VALUES (N'00000000000000_Empty', N'7.0.0-test');
871871
872872
--Before
873873
@@ -910,18 +910,18 @@ CONSTRAINT [PK_Blogs] PRIMARY KEY ([Id])
910910
END
911911
912912
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
913-
VALUES (N'00000000000001_Migration1', N'9.0.0');
913+
VALUES (N'00000000000001_Migration1', N'7.0.0-test');
914914
915915
--After
916916
917917
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
918-
VALUES (N'00000000000002_Migration2', N'9.0.0');
918+
VALUES (N'00000000000002_Migration2', N'7.0.0-test');
919919
920920
DECLARE @result int;
921921
EXEC @result = sp_releaseapplock @Resource = '__EFMigrationsLock', @LockOwner = 'Session';
922922
SELECT @result
923923
""",
924-
Fixture.TestSqlLoggerFactory.Sql,
924+
Fixture.TestSqlLoggerFactory.Sql.Replace(ProductInfo.GetVersion(), "7.0.0-test"),
925925
ignoreLineEndingDifferences: true);
926926
}
927927

0 commit comments

Comments
 (0)