Skip to content
This repository was archived by the owner on Jan 27, 2022. It is now read-only.

Commit 79c1842

Browse files
iscottb122Iain Scott
authored andcommitted
Improve English of exceptions.
1 parent 9d61368 commit 79c1842

5 files changed

Lines changed: 6 additions & 6 deletions

File tree

src/Winton.DomainModelling.DocumentDb/EntityFacade.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public EntityFacade(Database database, DocumentCollection documentCollection, ID
3232
{
3333
if (documentCollection.PartitionKey.Paths.Any())
3434
{
35-
throw new NotSupportedException("Partitioned collections not supported.");
35+
throw new NotSupportedException("Partitioned collections are not supported.");
3636
}
3737

3838
_database = database;
@@ -136,7 +136,7 @@ public async Task<TEntity> Upsert<TEntity, TEntityId>(TEntity entity)
136136
{
137137
if (Equals(entity.Id, default(TEntityId)))
138138
{
139-
throw new NotSupportedException("Upserting with default ID not supported.");
139+
throw new NotSupportedException("Upserting with default ID is not supported.");
140140
}
141141

142142
var document = new EntityDocument<TEntity, TEntityId>(entity);

src/Winton.DomainModelling.DocumentDb/ValueObjectFacade.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public ValueObjectFacade(
3333
{
3434
if (documentCollection.PartitionKey.Paths.Any())
3535
{
36-
throw new NotSupportedException("Partitioned collections not supported.");
36+
throw new NotSupportedException("Partitioned collections are not supported.");
3737
}
3838

3939
_database = database;

test/Winton.DomainModelling.DocumentDb.IntegrationTests/EntityFacadeTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ private void ShouldThrowIfIdUnset()
244244
Func<Task> action = _entityFacade.Awaiting(ef => ef.Upsert<TestEntity, EntityId>(entity));
245245

246246
action.Should().Throw<NotSupportedException>()
247-
.WithMessage("Upserting with default ID not supported.");
247+
.WithMessage("Upserting with default ID is not supported.");
248248
}
249249

250250
[Fact]

test/Winton.DomainModelling.DocumentDb.Tests/EntityFacadeTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ private void ShouldThrowIfPartitionKeyIsSpecified()
3838
Action constructing = Constructing(() => new EntityFacade(null, documentCollection, null));
3939

4040
constructing.Should().Throw<NotSupportedException>()
41-
.WithMessage("Partitioned collections not supported.");
41+
.WithMessage("Partitioned collections are not supported.");
4242
}
4343
}
4444
}

test/Winton.DomainModelling.DocumentDb.Tests/ValueObjectFacadeTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ private void ShouldThrowIfPartitionKeyIsSpecified()
3838
Action constructing = Constructing(() => new ValueObjectFacade(null, documentCollection, null));
3939

4040
constructing.Should().Throw<NotSupportedException>()
41-
.WithMessage("Partitioned collections not supported.");
41+
.WithMessage("Partitioned collections are not supported.");
4242
}
4343
}
4444
}

0 commit comments

Comments
 (0)