Skip to content

ragavsathish/mmockito

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mmockito - MATLAB mock framework based on Java Mockito

The latest version can always be downloaded from Github:

  https://github.com/vperic/mmockito

The project mailing list can be found on Google Groups:

  https://groups.google.com/forum/#!forum/mmockito

mmockito is distributed under the BSD license. All contributions are 
welcome!

Issues can be reported on the projects' Github page; code should also be 
submitted as pull requests. Pull requests should include the 
necessary tests; tests should be passing at all times.

Usage
=====

The 'mmockito' directory should be added to MATLAB's path; it contains the most
used classes. The main functionality is provided by the "Mock" class, which
supports both stubbing and verification. In-order verification is provided by
the "InOrder" class. The "Matcher" class is an interface for specifying
argument matchers, "Any", "ArgThat" and "AnyArgs" are commonly used matchers.
Some further matchers are provided in the mmockito.matchers package. The
mmockito.internal package has internal class which should not be used by
end-users.

For more detailed information consult the help files of individual classes.

More documentation, including a detailed overview of features and 
comparison to Java Mockito, are available in my bachelor's thesis:

  http://cyber.felk.cvut.cz/research/theses/detail.phtml?id=407

Tests
=====

To run tests, use the runtests function, which returns a TestResult object:

    r = runtests('all');

Other options are 'acceptance', 'unit', or the exact name of a unit test file.

MATLAB 2013a or higher is required to run the tests.

About

mmockito is a MATLAB mock framework based on Java Mockito.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • MATLAB 99.0%
  • M 1.0%