#!/usr/bin/env python
import os
from coral.modeler import modeler,action

m=modeler.ModelerWindow()

m.main(loop=0)

s=action.newProject(["UML", 1, 4])
action.saveProjectAs("tmp/foo.xml", "2.0")

assert not os.system("grep -q \"version='2.0'\" tmp/foo.xml")


assert s
assert s.getFilename()

action.saveProject()

assert not os.system("grep -q \"version='2.0'\" tmp/foo.xml")
