Rubberduck: Class not registered error while running tests

Created on 18 Oct 2020  路  2Comments  路  Source: rubberduck-vba/Rubberduck

Rubberduck version information
The info below can be copy-paste-completed from the first lines of Rubberduck's log or the About box:

Rubberduck version [2.5.1.5585]
Operating System: [Win10 6.2.9200.0]
Host Product: [VB6]
Host Version: [6.00.9782]
Host Executable: [VB6.EXE]

Description
Trying to restore an object from a PropertyBag.ReadProperty("sut") causes runtime error 713: Class not registered. Looking for object with CLSID {changes every time}

To Reproduce
Steps to reproduce the behavior:

  1. Create unit test
  2. Persist object to disk using PropertyBag.WriteProperty("sut", sut)
  3. Try to rehydrate the object using PropertyBag.ReadProperty("sut")
  4. See error

Expected behavior
All other tests pass including writing to a custom XMLPropertyBag that persists the object as an xml file

Screenshots
If applicable, add screenshots to help explain your problem.

Logfile
RubberduckLog.txt

Additional context
Add any other context about the problem here.

bug

Most helpful comment

It seems that this was due to a conflict with SimplyVBUnit unit test suite. Loading just my dll project and using the RD Test runner without loading the whole project group that contains my dll project and SimplyVBUnit works as advertised.

All 2 comments

It seems that this was due to a conflict with SimplyVBUnit unit test suite. Loading just my dll project and using the RD Test runner without loading the whole project group that contains my dll project and SimplyVBUnit works as advertised.

Thanks for reporting! This is a known issue, something to do with how .NET handles COM interop types from different assemblies. For posterity, linking issue #3837 and #4041.

Was this page helpful?
0 / 5 - 0 ratings