Skip to content

Commit f96a66f

Browse files
committed
Rename #1460 tests to two-segment scenario names and tag the issue
1 parent c444bb2 commit f96a66f

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

test/Autofac.Specification.Test/Lifetime/InstancePerMatchingLifetimeScopeTests.cs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ namespace Autofac.Specification.Test.Lifetime;
99
public class InstancePerMatchingLifetimeScopeTests
1010
{
1111
[Fact]
12-
public void LocalRegistration_BindingToAncestorTag_ThrowsAtScopeCreation()
12+
public void LocalRegistration_BindToAncestorTag()
1313
{
14-
// Reproduces the exact memory-leak scenario from issue #1460:
14+
// #1460: Reproduces the exact memory-leak scenario from the issue.
1515
// A child scope is created with a local registration whose matching-scope
1616
// tag refers to an ancestor (the outer scope). Each BeginLifetimeScope call
1717
// would hoist a fresh instance into the ancestor indefinitely, so we now
@@ -27,9 +27,9 @@ public void LocalRegistration_BindingToAncestorTag_ThrowsAtScopeCreation()
2727
}
2828

2929
[Fact]
30-
public void LocalRegistration_BindingToScopeOwnTag_DoesNotThrow()
30+
public void LocalRegistration_BindToScopeOwnTag()
3131
{
32-
// A scope-local registration whose MatchingScopeLifetime tag matches the
32+
// #1460: A scope-local registration whose MatchingScopeLifetime tag matches the
3333
// NEW scope's own tag is perfectly legal: the component's lifetime exactly
3434
// matches its reachability, so there is no leak.
3535
var builder = new ContainerBuilder();
@@ -48,9 +48,9 @@ public void LocalRegistration_BindingToScopeOwnTag_DoesNotThrow()
4848
}
4949

5050
[Fact]
51-
public void LocalRegistration_BindingToDescendantTag_DoesNotThrow()
51+
public void LocalRegistration_BindToDescendantTag()
5252
{
53-
// A scope-local registration whose MatchingScopeLifetime tag will only be
53+
// #1460: A scope-local registration whose MatchingScopeLifetime tag will only be
5454
// matched by a future descendant scope must NOT throw at registration time —
5555
// this is the documented, intended usage pattern.
5656
var builder = new ContainerBuilder();
@@ -82,9 +82,9 @@ public void LocalRegistration_BindToGrandchildTag()
8282
}
8383

8484
[Fact]
85-
public void LocalRegistration_BindingToRootContainerTag_ThrowsAtScopeCreation()
85+
public void LocalRegistration_BindToRootContainerTag()
8686
{
87-
// The container's root tag is also a strict ancestor; binding to it from a
87+
// #1460: The container's root tag is also a strict ancestor; binding to it from a
8888
// scope-local registration should likewise be rejected.
8989
var builder = new ContainerBuilder();
9090
var container = builder.Build();
@@ -95,9 +95,9 @@ public void LocalRegistration_BindingToRootContainerTag_ThrowsAtScopeCreation()
9595
}
9696

9797
[Fact]
98-
public void LocalRegistration_BindingToAncestorTag_MultipleTagsOneAncestor_ThrowsAtScopeCreation()
98+
public void LocalRegistration_BindToMultipleTagsIncludingAncestor()
9999
{
100-
// When multiple tags are supplied to InstancePerMatchingLifetimeScope and at
100+
// #1460: When multiple tags are supplied to InstancePerMatchingLifetimeScope and at
101101
// least one of them refers to an ancestor, it must still throw.
102102
var builder = new ContainerBuilder();
103103
var container = builder.Build();

0 commit comments

Comments
 (0)