diff --git a/src/Famix-Python-Importer-Tests/FamixPythonProject1Test.class.st b/src/Famix-Python-Importer-Tests/FamixPythonProject1Test.class.st index 84b9d50..602c6f0 100644 --- a/src/Famix-Python-Importer-Tests/FamixPythonProject1Test.class.st +++ b/src/Famix-Python-Importer-Tests/FamixPythonProject1Test.class.st @@ -17,6 +17,14 @@ FamixPythonProject1Test >> model [ ^ FamixPythonProject1TestResource current model ] +{ #category : 'tests' } +FamixPythonProject1Test >> testModel [ + + self assert: self model isNotEmpty. + self assert: self model name equals: 'project1'. + self assert: self model rootFolder equals: FamixPythonBridge parsingExamples / 'project1' +] + { #category : 'tests - modules' } FamixPythonProject1Test >> testModuleInRootPackage [ diff --git a/src/Famix-Python-Importer/FamixPythonImporter.class.st b/src/Famix-Python-Importer/FamixPythonImporter.class.st index 34464c8..919499d 100644 --- a/src/Famix-Python-Importer/FamixPythonImporter.class.st +++ b/src/Famix-Python-Importer/FamixPythonImporter.class.st @@ -34,11 +34,14 @@ FamixPythonImporter >> import: aFileName [ visitor rootFilePath: aFileName. fileReference := aFileName asFileReference. - visitor model name: fileReference basename. + visitor model + name: fileReference basename; + rootFolder: aFileName asFileReference. + self importFileReference: fileReference. - ^visitor model + ^ visitor model ] { #category : 'api' }