Module not found in Test-Swift.h


(David Catmull) #1

In my test target, when I include the Test-Swift.h file, there is a line
that says "@import MyAppName" which yields the error "Module 'MyAppName'
not found". Turning on the Defines Module setting for my app target didn't
help. So why is that import there, and what is required for it to be found?


(Jordan Rose) #2

Hm, it definitely shouldn't be importing the app (since there's not a real Objective-C module there). This might be a known issue, but I'm not sure offhand. Can you file an issue at bugs.swift.org <http://bugs.swift.org/>?

···

On Dec 9, 2016, at 09:10, David Catmull via swift-users <swift-users@swift.org> wrote:

In my test target, when I include the Test-Swift.h file, there is a line that says "@import MyAppName" which yields the error "Module 'MyAppName' not found". Turning on the Defines Module setting for my app target didn't help. So why is that import there, and what is required for it to be found?
_______________________________________________
swift-users mailing list
swift-users@swift.org
https://lists.swift.org/mailman/listinfo/swift-users


(David Catmull) #3

Done: https://bugs.swift.org/browse/SR-3381

Any suggestions for a workaround? Or should I watch the bug report for that?

···

On Fri, Dec 9, 2016 at 10:59 AM, Jordan Rose <jordan_rose@apple.com> wrote:

Hm, it definitely shouldn't be importing the app (since there's not a real
Objective-C module there). This might be a known issue, but I'm not sure
offhand. Can you file an issue at bugs.swift.org?

On Dec 9, 2016, at 09:10, David Catmull via swift-users < > swift-users@swift.org> wrote:

In my test target, when I include the Test-Swift.h file, there is a line
that says "@import MyAppName" which yields the error "Module 'MyAppName'
not found". Turning on the Defines Module setting for my app target didn't
help. So why is that import there, and what is required for it to be found?
_______________________________________________
swift-users mailing list
swift-users@swift.org
https://lists.swift.org/mailman/listinfo/swift-users


(Jordan Rose) #4

:frowning: I can't think of one, sorry. Mixed-source unit test targets have been a lower priority, especially importing the Swift side into Objective-C.

Jordan

···

On Dec 9, 2016, at 10:20, David Catmull <davidcatmull@gmail.com> wrote:

Done: https://bugs.swift.org/browse/SR-3381

Any suggestions for a workaround? Or should I watch the bug report for that?

On Fri, Dec 9, 2016 at 10:59 AM, Jordan Rose <jordan_rose@apple.com <mailto:jordan_rose@apple.com>> wrote:
Hm, it definitely shouldn't be importing the app (since there's not a real Objective-C module there). This might be a known issue, but I'm not sure offhand. Can you file an issue at bugs.swift.org <http://bugs.swift.org/>?

On Dec 9, 2016, at 09:10, David Catmull via swift-users <swift-users@swift.org <mailto:swift-users@swift.org>> wrote:

In my test target, when I include the Test-Swift.h file, there is a line that says "@import MyAppName" which yields the error "Module 'MyAppName' not found". Turning on the Defines Module setting for my app target didn't help. So why is that import there, and what is required for it to be found?
_______________________________________________
swift-users mailing list
swift-users@swift.org <mailto:swift-users@swift.org>
https://lists.swift.org/mailman/listinfo/swift-users