· Sep 19, 2017 1m read

UnitTest : A Mocking Framework for InterSystems objectscript classes.

It is with great pleasure that the CIUSSS de l'Estrie - CHUS is sharing the mocking framework it developed and presented at the InterSystems Summit 2017.  I will update this post with more detailed instructions in the next few weeks but I wanted to share the code and presentation quickly :

I hope you'll find this useful for your unit testing. We are using this extensively for the last 2 years and it really works well! The repo is public, feel free to submit enhancements!

Do not forget to enable the %UnitTest in your SMP. Instructions are online at

Kind regards

André-Claude Gendron

Discussion (14)6
Log in or sign up to continue

Hi Andre Claude,

Thank you for sharing your framework, and for great presentation at Global Summit. I'm looking forward to see your detailed article in Developers Community!

We have a documentation available online, you can link directly to it:

Also, video recording of Andre's presentation and PDF of his slides are available at

Hi Andre-Claude,

Thank you for the contribution! We've begun to fold the use of this Mock framework into our daily activities.

I know this post is rather old, but I do have a question. Some of the classes in the repository use classes that are not present in the repo any where (Tests.Fw.Mock.CIsEqualObjectParamValidator for example). If you are willing, would you be able to commit those to the GitLab site?

Again, thank you for sharing this with the rest of us.


I know it is a old thread but I thought I'd ask if there are any updates to this framework? The repo is 4 years old and I'm looking for a solution for a mocking framework atm. I noticed also that some classes are missing like Jonathan Lent stated. Is there any possibility for you to update the repo with the latest changes if there are any? I'm working on unit tests and trying to find out a way to mock different business hosts and I found this framework to be a promising one.


I just remembered, I fixed this but was waiting for a review. I merged it this morning.

(code was sent to github per InterSystems request)

Latest code is here :

Let me know if you need something else. Have a look at the CTestCustomPassthroughOperation.cls class