# HG changeset patch # User telesto # Date 1513836115 -3600 # Thu Dec 21 07:01:55 2017 +0100 # Node ID 3236449f679698e916c604d8dc3f45bee2ac7369 # Parent e7b75868af27c3e4239a9cf9ba637f41a3e5d8c3 finally got rid of convey diff --git a/event_test.go b/event_test.go --- a/event_test.go +++ b/event_test.go @@ -17,8 +17,6 @@ import ( "testing" "time" - - . "github.com/smartystreets/goconvey/convey" ) func eventLoop(s Screen, evch chan Event) { @@ -37,13 +35,7 @@ func TestMouseEvents(t *testing.T) { - Convey("Mouse events", t, WithScreen(t, "", func(s SimulationScreen) { - - Convey("Size should be valid", func() { - x, y := s.Size() - So(x, ShouldEqual, 80) - So(y, ShouldEqual, 25) - }) + WithScreen(t, "", func(s SimulationScreen) { s.EnableMouse() s.InjectMouse(4, 9, Button1, ModCtrl) @@ -64,14 +56,11 @@ done = true } } - Convey("We got our mouse event", func() { - So(em, ShouldNotBeNil) - x, y := em.Position() - So(x, ShouldEqual, 4) - So(y, ShouldEqual, 9) - So(em.Buttons(), ShouldEqual, Button1) - So(em.Modifiers(), ShouldEqual, ModCtrl) - }) - })) - + assertNotEqual("mouse event", em, nil, t) + x, y := em.Position() + assertEqual("x", x, 4, t) + assertEqual("y", y, 9, t) + assertEqual("buttons", em.Buttons(), Button1, t) + assertEqual("mods", em.Modifiers(), ModCtrl, t) + })() }