Trouble for Unit Tests

Speckle Community,

Hello, my name is Jacob Smith and I am a software developer for Simpson Stong Tie. We plan to use the Xunit Test runner for to write unit tests for our developer environment. I am running into a few issues when trying to write simple transactions to modify the document to set up the post commands for our Revit addin. I have followed what Connor Ivy has implemented on his video on YouTube, where he is copying walls and verifying that parameters are equal to each other however I am having trouble just changing the active view in the project. I have followed a few work around on Jeramy Tammiks building coder blog also and I am not having any luck. I am hoping to get in touch with someone from the development team to help my team and myself get this set up correctly.

Thank you,

1 Like

Welcome @jacsmith ,

What error are you getting?

@teocomi Revit can not make changes to a read only document. This is odd because in the properties of the revit project the read only check box is not checked.

I have’t seen this before…
Some things that come to mind:

  • if you’re opening an existing project, make sure to activate it (there’s something in the API to do so)
  • try maybe creating a brand new project. That for sure should be editable

The problem is of the misusage of Revit API. @jacsmith it is not allowed to change the active view within a transaction.

1 Like

Which incidentally is also why Phases can’t be handled properly on receiving.

1 Like

In the revit api or through the speckle solution?