Commit Graph

44 Commits

Author SHA1 Message Date
Pietro Gagliardi c269d1f6bc Started re-integrating test/events.c. It doesn't quite work yet, but it appears I need to reboot AGAIN because now both acme and pbcopy/pbpaste are being dumb with the clipboard... 2020-02-17 15:01:20 -05:00
Pietro Gagliardi 75db846736 Looks like we're going to need to turn the test suite into a subprocess-based suite now rather than later, because of Haiku not allowing BApplication::Run() to be called more than once. 2020-01-19 18:59:43 -05:00
Pietro Gagliardi a9145c2f35 Started writing the uiControl functionality tests. Also more TODOs. Let's fix build errors next. 2019-06-16 21:44:49 -04:00
Pietro Gagliardi d54f23c0cc Deduplicated the common defer functions. 2019-06-13 10:39:40 -04:00
Pietro Gagliardi c1ca78c46e Split the events.c errors test into its own file. 2019-06-12 11:12:08 -04:00
Pietro Gagliardi 7e3d6d2b1c And fixed build and runtime errors. This works! Woo! We can now move on to uiControl for real this time! (Will resolve the TODOs later.) 2019-06-10 11:36:44 -04:00
Pietro Gagliardi a0fc3187e2 And rewrote events.c to use the new error checking framework. Now to fix build and possibly runtime errors. 2019-06-10 11:24:33 -04:00
Pietro Gagliardi 7b10fa729b More TODOs. 2019-06-10 10:42:11 -04:00
Pietro Gagliardi afbf5f2d59 And actually did split the new error testing code into its own file. Next is changing both events.c and controls.c to use it (and yes, that means we can finally start continuing work on controls.c). 2019-06-09 22:45:44 -04:00
Pietro Gagliardi ef05d40fad Fixed test execution. 2019-06-09 18:19:43 -04:00
Pietro Gagliardi a0fd823328 Just restored TestEventErrors as is for now. There's definitely room for cleanup here. 2019-06-09 18:08:50 -04:00
Pietro Gagliardi 24320ce784 Disabled the event error tests and started rewriting the no uiInit()/wrong thread checks to use the new programmer error test hooks. I'll also start taking care of the sharedbits cruft now by just providing Strdup and FreeStrdup as utility functions, because bleh. 2019-06-09 13:57:02 -04:00
Pietro Gagliardi e808d85e01 Added function names to the wrong struct size error. 2019-06-09 08:50:12 -04:00
Pietro Gagliardi 6f4c65defc Finished the uiEventInvalidateSender() tests. 2019-06-07 21:05:45 -04:00
Pietro Gagliardi 5260d5c90f More reminders for when I write the rest of the uiEventInvalidateSender() tests later. 2019-06-07 11:01:17 -04:00
Pietro Gagliardi 6cf92b2058 Wrote and started testing uiEventInvalidateSender(). The rest of the tests come next. 2019-06-07 10:58:39 -04:00
Pietro Gagliardi 26e492539d Renamed uiFreeEvent() to uiEventFree() for consistency with uiControlFree(). 2019-06-02 22:04:25 -04:00
Pietro Gagliardi c6294f163f Okay, added uiFreeEvent() error tests. Now back to uiControl. 2019-06-02 19:11:22 -04:00
Pietro Gagliardi ddaa10b7e1 Wrote defers into test/events.c. Woo! Now we need to free the defers when we're done, and I have an idea... 2019-06-02 12:48:06 -04:00
Pietro Gagliardi 3f4765d116 Renamed diffx() to diff(). 2019-06-02 01:59:08 -04:00
Pietro Gagliardi 0c673acf70 Got rid of all the diff() macros; the replacement, currently called diffx(), just produces the requisite format string. Next up is renaming diffx() to diff() and making sure things work. 2019-06-02 01:51:40 -04:00
Pietro Gagliardi 1cf545d369 Started mapping filenames and line numbers back to their appropriate places in the tester. 2019-06-02 01:13:56 -04:00
Pietro Gagliardi 48cd6e1dd8 Cleaned #include directives so C standard library headers are sorted and so each source file only includes one header file. This makes things clenaer, and alos allows us to more properly strip unneeded headers later. 2019-06-01 09:27:17 -04:00
Pietro Gagliardi afb87bda23 And filled in the remainder of the uiEvent error tests. Also more TODOs. We can now FINALLY move on to uiControl :D 2019-05-26 21:59:59 -04:00
Pietro Gagliardi 7cb4f010d4 Cleaned up programmer error testing code. 2019-05-26 20:19:02 -04:00
Pietro Gagliardi 7808b3ee94 Added the hook for checking programmer error responses, and made sure it works. Now to simplify it. 2019-05-26 15:41:22 -04:00
Pietro Gagliardi e4f5b4f548 And filled in the missing gaps in the non-error cases of the uiEvent tests. Almost ready to move on! 2019-05-26 15:06:28 -04:00
Pietro Gagliardi dbbf84becc Filled in the rest of TestEventBlocksHonored. 2019-05-26 13:26:58 -04:00
Pietro Gagliardi b8b1123027 And rewrote TestEventBlocksHonored. Now we can expand it. 2019-05-25 22:30:08 -04:00
Pietro Gagliardi f77f8d49d3 Restructured TestEventSendersHonored to use the new deinterleaved handler; this also makes it use baseParams and creates events per impl rather than globally. 2019-05-25 22:21:16 -04:00
Pietro Gagliardi a8ab5be01a Started deinterlacing the handler got and want parameters into struct handler. 2019-05-25 22:07:56 -04:00
Pietro Gagliardi 3cd08a5b2d Simplified the event structures. Next step is to deduplicate handlers. 2019-05-25 21:19:22 -04:00
Pietro Gagliardi c41ac17dd4 Rewrote test/events.c to localize the actual uiEventFire() testing code. 2019-05-25 21:11:03 -04:00
Pietro Gagliardi d6cde02825 More event tests. Okay, I definitely need a better way to handle these. 2019-05-23 21:42:52 -04:00
Pietro Gagliardi 5a6c302ae0 Added TestEventSendersHonored. 2019-05-22 11:44:30 -04:00
Pietro Gagliardi bf3492cd9c Cleaned up event test names. 2019-05-22 11:16:15 -04:00
Pietro Gagliardi d346a8ca8e Laid out the other things to test for events.c. 2019-05-21 21:12:01 -04:00
Pietro Gagliardi 43fd636071 And cleaned up the subtest architecture and made both tests properly subtested. Now for the rest of the tests. 2019-05-21 21:01:13 -04:00
Pietro Gagliardi bf1172bc0a Parameterized TestBasicEventsAddDeleteEventHandlers. Now we'll split it into subtests. 2019-05-21 20:16:41 -04:00
Pietro Gagliardi 7be128d5bb Changed TestBasicEventsSingleHandler to use subtests. It works! 2019-05-20 22:20:04 -04:00
Pietro Gagliardi 35759935ae Added more cases to the AddDelete tests. Now to add subtests so we can more easily pluralize these tests, including handling cases of different senders. 2019-05-19 01:06:43 -04:00
Pietro Gagliardi 973696137f Reduced noise in event tests when a handler that should have run did not run. 2019-05-18 22:21:23 -04:00
Pietro Gagliardi 3b1f5e0e54 Added more event tests. DeleteHandler obviously does not work... and I really need to add subtests. 2019-05-18 21:21:55 -04:00
Pietro Gagliardi 43f7d1a661 Started the events test suite. 2019-05-18 13:26:55 -04:00