#!/usr/bin/env python
import coral
xmidi=coral.lang.XMIDI20 
d = xmidi.Diagram()
a = xmidi.DiagramLink()

print d.owner
try:
    d.owner = a
except RuntimeError, e:
    print e
    print "(The above error message is expected)"
    assert str(e).find("WRONG TYPE DiagramLink should be SemanticModelBridge") != -1
    pass
else:
    print "Dang, something is wrong."
    assert(0)

