From b040bf1a8716780a289e25c736a05b444113c913 Mon Sep 17 00:00:00 2001 From: Felipe Muniz Date: Sun, 1 Sep 2024 23:36:39 -0300 Subject: [PATCH] fix: remove deprecated custom plugin test --- .../PlugInManagerTest.cs | 45 ------------------- 1 file changed, 45 deletions(-) diff --git a/tests/MUnique.OpenMU.PlugIns.Tests/PlugInManagerTest.cs b/tests/MUnique.OpenMU.PlugIns.Tests/PlugInManagerTest.cs index f736586aa..feb8a1012 100644 --- a/tests/MUnique.OpenMU.PlugIns.Tests/PlugInManagerTest.cs +++ b/tests/MUnique.OpenMU.PlugIns.Tests/PlugInManagerTest.cs @@ -156,51 +156,6 @@ public async ValueTask CreatedAndActiveByConfigurationAsync(bool active) Assert.That(args.WasExecuted, Is.EqualTo(active)); } - /// - /// Tests if a custom plugin gets created and executed. - /// - [Test] - public async ValueTask CustomPlugInByConfigurationAsync() - { - var configuration = new PlugInConfiguration - { - TypeId = new Guid("4EC93343-DE05-4449-B312-04005547266C"), - IsActive = true, - CustomPlugInSource = @" - namespace test - { - using System.Runtime.InteropServices; - using MUnique.OpenMU.GameLogic; - using MUnique.OpenMU.PlugIns; - using MUnique.OpenMU.PlugIns.Tests; - - [Guid(""4EC93343-DE05-4449-B312-04005547266C"")] - [PlugIn(""foo"", ""Just an example example plugin."")] - internal class ExamplePlugIn : IExamplePlugIn - { - /// - /// Gets a value indicating whether the plugin instance was executed in the test. - /// - public bool WasExecuted { get; private set; } - - public void DoStuff(Player player, string text, MyEventArgs args) - { - this.WasExecuted = true; - args.Text = ""CustomPlugIn""; - } - } - }", - }; - var manager = new PlugInManager(new List { configuration }, new NullLoggerFactory(), this.CreateServiceProvider(), null); - var player = await TestHelper.CreatePlayerAsync().ConfigureAwait(false); - var command = "test"; - var args = new MyEventArgs(); - - var point = manager.GetPlugInPoint(); - point!.DoStuff(player, command, args); - Assert.That(args.Text, Is.EqualTo("CustomPlugIn")); - } - /// /// Tests if a custom plugin in a non-existing assembly is not created and throws no errors. ///