Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

Multi-version NUnit testing framework for Revit API.

ricaun
Advisor

Multi-version NUnit testing framework for Revit API.

ricaun
Advisor
Advisor

Hello everyone, after some years of development my Test framework for Revit API is released.

 

ricaun.RevitTest is a multi-version NUnit testing framework for Revit API. Support Revit 2019 to 2025.

 

Features:

  • Run tests and debug using Visual Studio to execute tests inside Revit.
  • Open and Close Revit and dotnet test execution.
  • Auto detect Revit installation and no manual plugin installation required.

 

The whole project is open-source with all the utility packages.

 

 

The best way to start is download the sample project.

For help and discussion:

 

Luiz Henrique Cassettari

ricaun.com - Revit API Developer

AppLoader EasyConduit WireInConduit ConduitMaterial CircuitName ElectricalUtils

Reply
507 Views
8 Replies
Replies (8)

jeremy_tammik
Autodesk
Autodesk

Wow, brilliant! Thank you ever so much, @ricaun !  I wish you a happy and peaceful midwinter break!

   

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open

borkheather375
Observer
Observer

Thank you so much. 

0 Likes

soonhui
Collaborator
Collaborator

Coming from AUTOCAD/Civil 3D ( and writing plugins for Civil 3D), that's really great! 

 

Any chance that you will port this to Civil 3D as well?

##########

Ngu Soon Hui

##########

I'm the Benevolent Dictator for Life for MiTS Software.

Read more at here

0 Likes

ricaun
Advisor
Advisor

I don't have the incentive to port to AutoCAD/Civil, the whole project does not worth, only if you create a command line application to use AutoCAD and make the test adapter to use that application.

That's already implemented in the TestAdapter, so I can change some configuration and run tests using Design Automation for Revit instead of the Revit desktop version.

 

mermaid-diagram-2025-01-03-082719.png

That was the main goal of the project to enable to run locally with Revit for Desktop or in the cloud using Design Automation with the same test input.

 

Anyway you could create a discussion in the https://github.com/ricaun-io/ricaun.RevitTest/discussions.

I don't have so much knowledge with AutoCAD API to be able to find the similar implementation from Revit API to AutoCAD API.

 

Probably the first one would be to create a command line application to run tests in Design Automation for AutoCAD, that is less complex and not require to find AutoCAD in the local machine.

Using this package that already support Design Automation for AutoCAD: https://github.com/ricaun-io/forge-api-dotnet-oss.design.automation

 

Is the same one I'm using in the https://github.com/ricaun-io/ricaun.DA4R.NUnit to run tests using Design Automation for Revit. (The repo is in private at the moment.)

 

In the end you could sponsor the project, that's a good incentive. 🤘

 

Luiz Henrique Cassettari

ricaun.com - Revit API Developer

AppLoader EasyConduit WireInConduit ConduitMaterial CircuitName ElectricalUtils

jeremy_tammik
Autodesk
Autodesk

Hi @ricaun ,

  

thank you very much for implementing and sharing this great tool!

   

I have one quick questions: I assume that you are aware of and have evaluated the Dynamo Revit Test Framework (RTF):

   

  

Can you confirm that, please, and possible share a word or two on what advantages ricaun.RevitTest offers over and above RTF and other prior unit testing frameworks? 

   

Muito obrigado!

   

Jeremy

   

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
0 Likes

ricaun
Advisor
Advisor

Hey @jeremy_tammik


The Dynamo Revit Test Framework (RTF) looks abandoned in GitHub and I don't think works with Revit 2025 that uses .NET Core.

 

Using ricaun.RevitTest is really convenient to be able to execute tests inside Visual Studio Test Explorer.

 


Some ricaun.RevitTest features would be:

  • Support multiple Revit versions (2019-2025) (Revit Preview)
  • Runs inside Visual Studio Test Explorer (dotnet test)
  • Do not require any manual plugin installation.
  • Support to run tests using Design Automation for Revit.

 

About running tests using Design Automation for Revit, I have a class session in DevCon Europe this year about ricaun.RevitTest.

 

Gonna share everything in my youtube channel. 

Luiz Henrique Cassettari

ricaun.com - Revit API Developer

AppLoader EasyConduit WireInConduit ConduitMaterial CircuitName ElectricalUtils

0 Likes

jeremy_tammik
Autodesk
Autodesk

Brilliant! Thank you very much for the very helpful and detailed in-depth explanation!

  

Good luck with your class at DevCon; sounds great!

  

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open

borkheather375
Observer
Observer

Thanks for sharing, I appreciate it.

Type a product name