This repository is a collection of methods for working with critical regions or testing of new methods
- Lock interfaces
- Fix number lock interfaces
- Race condition demonstration
- Dekker lock
- Framework for mutual exclusion testing
Demonstration is implemented in a form of unit tests which can be found here
Following interfaces and abstractions are implemented:
- FixNumLock (i);
- FixNumLockN (a);
- BinaryLock (a);
- DekkerLock
- FakeLock (for false case demonstration of mutual exclusion testing framework)
To create a new unit test, you have to extend MutualExclusionTest<LockClass>
class by implementing methods:
prephase
lockAction
unlockAction
such methods will be called during testing with providesMutualExclusion(LockClass testableLock)
method