Commit graph

47 commits

Author SHA1 Message Date
f6af4c6a16 Dispatcher-Pipeline: prepare test for the new NodeGraphAttachment
It turns out that the real (not mocked) implementation of JobTicket creation
is already required now for this planned (mock)Dispatcher setup;
moreover, this real implementation turns out to be almost identical
to the mock implementation written recently -- just nested structure
of prerequiste JobTickets need to be changed into a similar structur
of ExitNodes

-- as an aside: rearrange various tests to be more in-line
   with the envisioned architecture of playback and engine
2023-06-07 04:03:00 +02:00
9e951e1eeb Global-Layer-Renaming: adapt lots of documentation 2018-11-15 21:13:52 +01:00
876c1dd1fd Commands: change implementation frame to include the command-ID
while the initial design treated the commands in a strictly top-down manner,
where the ID is known solely to the CommandRegistry, this change and information
duplication became necessary now, since by default we now always enqueue and
dispatch anonymous clone copies from the original command definition (prototype).

This implementation uses the trick to tag this command-ID when a command-hanlde
is activated, which is also the moment when it is tracked in the registry.
2017-04-17 03:09:12 +02:00
a91d03b60a Commands: draft usage of CommandInstanceManager (#1089) 2017-04-01 02:33:15 +02:00
95af930a71 Commands: finish CommandSetup helper (#1088)
this is a prerequisite for command instance management:
We have now an (almost) complete framework for writing actual
command definitions in practice, which will be registered automatically.

This could be complemented (future work) by a script in the build process
to regenerate proc/cmd.hpp based on the IDs of those automatic definitions.
2017-03-31 18:30:29 +02:00
8a0f26c787 start and stop the Dispatcher for running the function(integration) test
need also to start and stop the interface registry,
since by policy we do not run the application framework itself
for execution of the test suite; thus if some test actually needs
an application service, it must be started/stopped manually
2017-01-11 05:01:47 +01:00
282829956b ProcDispatcher: integrate queue and finish preliminary implementation draft
TODO: the wakeup / notification on changes still needs to be done consistently
2016-12-25 22:26:16 +01:00
b58427e49f Command-Framework: mark anonymous commands
It turns out we *do* support the use of anonymous commands
(while it is not clear yet if we really need this feature).

Basically, client code may either create and register a new
instance from another command used as prototype, by invoking
Command::storeDef(ID). Or, alternatively it may just invoke
newInstance() on the command, which creates a new handle
and a valid new implementation (managed by the handle as
smart-ptr), but never stores this implementation into the
CommandRegistry. In that case, client code may use such a
command just fine, as long as it cares to hold onto that
handle; but it is not possible to retrieve this command
instance later by symbolic ID.

In the light of this (possible) usage pattern, it doesn't
make sense to throw when accessing a command-ID. Rather, we
now return a placeholder-Symbol ("_anonymous_")
2016-12-25 21:46:58 +01:00
00077d0431 ProcDispatcher: decide on requirements and implementation structure (#1049) 2016-12-15 20:48:35 +01:00
35fbd9fa1e immutable-arguments(#989): add a first-class unit test (closes #989)
the functionality as such is already covered,
but it seems important enough to warrant a dedicated test.


incidentally, Duration still lacked a default ctor.
Time values are default constructible, yet immutable.
2016-02-07 02:59:03 +01:00
e0f866092d rectify-design(#301): disentangle CmdClosure hierarchy
Completely removed the nested hierarchy, where
the top-level implementation forwarded to yet another
sub-implementation of the same interface. Rather, this
sub-implementation (OpClosure) is now a mere implementation
detail class without VTable, and without half-baked
re-implementation of the CmdClosure interface. And the
state-switch from unbound to bound arguments is now
implemented as a plain-flat boolean flag, instead of
hiding it in the VTable.

To make this possible, without having to rewrite lots of
tests, I've created a clone of StorageHolder as a
"proof-of-concept" dummy implementation, for the sole
purpose of writing test fixtures. This one behaves
similar to the real-world thing, but cares only
for closing the command operation and omits all
the gory details of memento capturing and undo.
2016-02-07 01:41:40 +01:00
be2179ea81 command-closure-design(#301): better naming of implementation classes
Seems this was part of the confusion when looking at
the inheritance graph: Names where almost reversed
to the meaning. the ArgumentHolder was *not* the
argument holder, but the top level closure. And
the class "Closure" was not "the" Closure, but
just the argument holder. ;-)
2016-02-06 16:29:06 +01:00
f2cbac14e2 test-suite: fix lots of missing return value checks
without that check, in theory our test runner will tolerate
a non-zero return value, like throwing or failing an assert,
which is not what we want....

guess these happenend to get in by forgetting to
add this check when switching a test from PLANNED to TEST
2016-01-28 22:30:24 +01:00
005e665c13 clean-up design of the command handling patterns (#210)
this was a classical example of a muddled and messed-up design,
driven just by the fact that I wanted to "spare" some functions,
with the net effect of writing more functions, plus a proxy class
plus create a lot of confusion for the reader.

This was easy to resolve though, once I resorted to the
general adivice to make public interface methods final,
make the extension ponts protected and never
to chain two extension points
2016-01-22 15:25:08 +01:00
ecd1375e92 fix and adjust broken test defintions. Closes #985 2016-01-10 12:25:45 +01:00
034d5f99dc fix and adjust various test fixtures
due to the new automatic string conversion in operator<<
the representation of objects has changed occasionally.

I've investigated and verified all those incidents.
2016-01-08 00:16:14 +01:00
7b7d12d99e add internal / diagnostic display for low-level time values and time spans
Initially I've deliberately omitted those, to nudge towards
using time quantisation and TCode formatting for any external
representation of time values.

While this recommendation is still valid, the overloaded
string conversion turns out to be helpful for unit testing
and diagnostics in compound data structures.
See Record<GenNode>
2015-09-25 03:12:04 +02:00
ada5cefaaf re-arrange tests according to layer structure
the buildsystem will now pick up and link
all test cases according to the layer, e.g.
backend tests will automatically be linked
against the backend + library solely.
2013-01-07 05:43:01 +01:00
14bc7d1fd4 fix regression in test definition
random time values are really random. Doh!
2011-09-25 19:16:13 +02:00
1aafb07a43 fix remaining issues turned up by switching the time handling 2011-05-20 03:39:07 +02:00
9d8961d650 Fix test definitions tue to the slightly changed time display format
In the course of the preceeding work, I changed the
standard Time formatting in time.c, such as to omit
the leading "0" on the hour; it doesn't seem likely
that displayed hour values will frequently have
two digits...
2011-01-13 03:36:11 +01:00
a85d885104 Fix RegExp causing MObjectRef_test to fail randomly
...by matching an LUID in the previous line.
Thanks to Cehteh for spotting this
2010-06-21 03:47:18 +02:00
cd51e5fef0 Proc Command handling frontend finished and usable for now
Additional convenience shortcuts and a bit of polishing.
Closes Ticket #300
2009-10-11 05:57:46 +02:00
c6d5f8a0b4 Proc Command framework: *first integraton round finished* 2009-10-11 05:57:46 +02:00
a4ad41a4e9 Idea how to solve the problem with cloning the UNDO functor 2009-10-11 05:57:45 +02:00
c8e049cdea Command system basic unit test pass 2009-10-11 05:57:44 +02:00
4f1c034b58 CommandRegistry: function test pass 2009-10-11 05:57:44 +02:00
96d5ce74c4 Ticket #292: outline unit test explicitly covering equality comparisions 2009-10-11 05:57:43 +02:00
39f50b548c Ticket #266: simplify and combine the bind(...) mixin templates into a single header 2009-10-11 05:57:43 +02:00
cb7c884293 handling patterns usable for now. Close #275 2009-10-11 05:57:42 +02:00
e9b95e47cf Command handling pattern? test-driven brainstorming 2009-10-11 05:57:40 +02:00
7f09f57cbd tests pass again 2009-09-21 03:34:10 +02:00
1533e5bd0d fix a problem with formatting arbitrary types; reneable the broken tests 2009-08-28 20:33:20 +02:00
08d4be3149 Fixes for building on 32bit system 2009-08-21 02:42:11 +02:00
a1ab90d435 disabled these tests for now, still WIP 2009-08-19 15:36:17 +02:00
a845a4d234 unit test covering the cmd registry 2009-08-11 08:35:37 +02:00
1db718c2b3 WIP more stubbing... 2009-07-25 19:21:50 +02:00
f40282b2ff WIP devised various aspects of command execution, drafted as unit test 2009-07-24 05:24:39 +02:00
c85d1d3cd8 ArgumentHolder finished, low-level integration test pass 2009-07-20 07:03:18 +02:00
fa3d596a59 helper for accepting arguments passes unit test 2009-07-12 23:21:37 +02:00
9aa5ba560c finish and tidy up control::Mutation, unit test pass 2009-07-10 19:04:01 +02:00
6bd1e8e179 tidy up and finish the MementoTie + unit test 2009-07-09 20:47:21 +02:00
51712f218d still fighting to get capture fun and undo func bound together 2009-06-28 15:27:27 +02:00
5ab8c126e0 WIP compilation fixes and stubs; split off MementoClosure (incl. separate unit test) 2009-06-24 06:38:33 +02:00
0ab5a92629 WIP: test-driven brainstorming... how to capture state and params. 2009-06-19 05:57:06 +02:00
3a7de1654a WIP: create a "scrapbook" test for trying out some ideas 2009-06-08 21:29:09 +02:00
6e12b74d9e rename the proc-layer tests to comply with the numbering scheme 2008-10-23 04:02:12 +02:00
Renamed from tests/55controller.tests (Browse further)