something

This commit is contained in:
2025-06-17 23:39:51 +02:00
parent 76b2c8c1bf
commit 518fd29d75
29 changed files with 118 additions and 101 deletions

View File

@@ -25,7 +25,7 @@ namespace Tests.Runtime.Engine {
public class DIContextTests {
[Test]
public void Single_Bind_And_Resolve() {
DIContext context = new();
DIContext context = new DIContext();
context.Bind<ITestService>(new TestServiceA());
ITestService testService = context.Resolve<ITestService>();
@@ -36,10 +36,10 @@ namespace Tests.Runtime.Engine {
[Test]
public void Single_Bind_And_Field_Inject() {
DIContext context = new();
DIContext context = new DIContext();
context.Bind<ITestService>(new TestServiceB());
TestObject obj = new();
TestObject obj = new TestObject();
context.Inject(obj);
Assert.IsNotNull(obj.Service, "obj.Service != null");
@@ -48,10 +48,10 @@ namespace Tests.Runtime.Engine {
[Test]
public void Single_Bind_And_Method_Inject() {
DIContext context = new();
DIContext context = new DIContext();
context.Bind<ITestService>(new TestServiceA());
TestObjectMethod obj = new();
TestObjectMethod obj = new TestObjectMethod();
context.Inject(obj);
Assert.IsNotNull(obj.Service, "obj.Service != null");