fix(tests): correct exception type expectation in ContentCrudServiceTests
The Create_WithNonExistentContentType test expected ArgumentException but ContentCrudService correctly throws generic Exception to match the original ContentService behavior (behavioral parity). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -133,7 +133,7 @@ public class ContentCrudServiceTests
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void Create_WithNullContentType_ThrowsArgumentException()
|
||||
public void Create_WithNonExistentContentType_ThrowsException()
|
||||
{
|
||||
// Arrange
|
||||
CreateMockScopeWithReadLock();
|
||||
@@ -141,7 +141,8 @@ public class ContentCrudServiceTests
|
||||
.Returns(Enumerable.Empty<IContentType>());
|
||||
|
||||
// Act & Assert
|
||||
Assert.Throws<ArgumentException>(() =>
|
||||
// Note: Throws generic Exception to match original ContentService behavior
|
||||
Assert.Throws<Exception>(() =>
|
||||
_sut.Create("Test", Constants.System.Root, "nonExistentType"));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user