public void AssertInvocationCountAutomaticExceptionGeneric()
        {
            Expect.Once.On(this.testInterfaceGeneric).EventAdd("MyEvent");
            var eventTester = new EventTester <EventArgs>(this.testInterfaceGeneric, "MyEvent", 1);

            this.mockery.VerifyAllExpectationsHaveBeenMet();

            Fire.On(this.testInterfaceGeneric).Event("MyEvent").With(null, EventArgs.Empty);
            Fire.On(this.testInterfaceGeneric).Event("MyEvent").With(null, EventArgs.Empty);

            Expect.Once.On(this.testInterfaceGeneric).EventRemove("MyEvent");

            Assert.Throws <EventTesterException>(
                () => eventTester.Dispose());

            this.mockery.VerifyAllExpectationsHaveBeenMet();
        }
        public void AssertInvocationCountAutomaticExceptionGeneric()
        {
            Expect.Once.On(this.testInterfaceGeneric).EventAdd("MyEvent");
            var eventTester = new EventTester<EventArgs>(this.testInterfaceGeneric, "MyEvent", 1);

            this.mockery.VerifyAllExpectationsHaveBeenMet();

            Fire.On(this.testInterfaceGeneric).Event("MyEvent").With(null, EventArgs.Empty);
            Fire.On(this.testInterfaceGeneric).Event("MyEvent").With(null, EventArgs.Empty);

            Expect.Once.On(this.testInterfaceGeneric).EventRemove("MyEvent");

            Assert.Throws<EventTesterException>(
                () => eventTester.Dispose());

            this.mockery.VerifyAllExpectationsHaveBeenMet();
        }