fix
This commit is contained in:
@@ -58,10 +58,7 @@ public class MigrationsTests : IDisposable
|
||||
[Fact]
|
||||
public void InitialCreateMigration_ShouldHaveCorrectConstants()
|
||||
{
|
||||
// Arrange
|
||||
var migration = new InitialCreate();
|
||||
|
||||
// Act & Assert
|
||||
// Arrange & Act & Assert
|
||||
// Use reflection to access private constants
|
||||
var migrationType = typeof(InitialCreate);
|
||||
|
||||
@@ -160,10 +157,11 @@ public class MigrationsTests : IDisposable
|
||||
var foreignKeys = chatMessageEntity.GetForeignKeys();
|
||||
foreignKeys.Should().HaveCount(1);
|
||||
|
||||
var foreignKey = foreignKeys[0];
|
||||
var foreignKey = foreignKeys.First();
|
||||
foreignKey.PrincipalEntityType.Should().Be(chatSessionEntity);
|
||||
foreignKey.Properties.Should().HaveCount(1);
|
||||
foreignKey.Properties[0].Name.Should().Be("SessionId");
|
||||
var properties = foreignKey.Properties;
|
||||
properties.Should().HaveCount(1);
|
||||
properties.First().Name.Should().Be("SessionId");
|
||||
foreignKey.DeleteBehavior.Should().Be(DeleteBehavior.Cascade);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user