Found the answer: The double quotes were actually the problem, I just forgot how to escape the single quotes (with additional single quotes):
(FAMIX.PrimitiveType (id: 101)
(name ''_unknown_file.int'')
)
Hi,In Moose 4.6 I load a simple MSE for my tests in the following way:loadIntoMoose: methodName
| model |
model := (MooseModel root entityNamed: methodName).
(model) notNil ifTrue: [^ model].
model := MooseModel new.
model name: methodName.
model importFromMSEStream: (ReadStream on: (self perform: methodName)).
model install.
^ modelWhere self perfom: methodName returns the MSE as String.This fails in Moose 4.7 in cacheMooseGroups here:allPrimitiveTypes
<navigation: 'All primitive types'>
^(self allWithType: FAMIXPrimitiveType) sorted: [:a :b | a name < b name]; yourself
There are three primitive types, but their names are nil.The peculiar thing is, if I load the MSE file in the Moose Panel manually it works (same content in the file and in the string!) and I can explore the three primitive types. They are (in the MSE):(FAMIX.PrimitiveType (id: 38)
(name "_unknown_file.void")
)
(FAMIX.PrimitiveType (id: 101)
(name "_unknown_file.int")
)
(FAMIX.PrimitiveType (id: 121)
(name "_unknown_file.boolean")
)The only difference between the MSE file and the String I return is that in the File ' are used and in the String " are used.So in the MSE file:(FAMIX.PrimitiveType (id: 38)
(name '_unknown_file.void')
)The String that I return in the method:^
'
...
(FAMIX.PrimitiveType (id: 38)
(name "_unknown_file.void")
)
...
'Is this a problem? Does anyone have an explanation for this behavior? Is there maybe a better way to load moose models for tests?If anyone wants to look at the code, it is available here:MCHttpRepository
location: 'http://www.squeaksource.com/Softwarenaut'
user: ''
password: ''Cheers,Dennis