Skip to content

[ModuleInterface] Use 2-arg form of basename(1) in overlay validation tests. #19942

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

graydon
Copy link
Contributor

@graydon graydon commented Oct 18, 2018

A bunch of .swiftinterface files fail to build into their respective .swiftmodules
if you pass -module-name for some foo that is not the correct module name.

The two tests in this change were using a shell expansion that incorrectly picked
the first path component with a period in the name as the module name; this caused
the failures.

Rather than using a shell expansion, this change uses the 2-argument form of
basename(1) (which is POSIX) that also removes a suffix from the basename.

rdar://45347391

… tests.

A bunch of .swiftinterface files fail to build into their respective .swiftmodules
if you pass -module-name <foo> for some foo that is not the correct module name.

The two tests in this change were using a shell expansion that incorrectly picked
the first path component with a period in the name as the module name; this caused
the failures.

Rather than using a shell expansion, this change uses the 2-argument form of
basename(1) (which is POSIX) that also removes a suffix from the basename.
@graydon
Copy link
Contributor Author

graydon commented Oct 18, 2018

@swift-ci please test and merge

@graydon
Copy link
Contributor Author

graydon commented Oct 19, 2018

@swift-ci please test linux platform

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - 9a3b232

@graydon
Copy link
Contributor Author

graydon commented Oct 19, 2018

@swift-ci please test linux platform

2 similar comments
@graydon
Copy link
Contributor Author

graydon commented Oct 19, 2018

@swift-ci please test linux platform

@graydon
Copy link
Contributor Author

graydon commented Oct 20, 2018

@swift-ci please test linux platform

@graydon
Copy link
Contributor Author

graydon commented Oct 20, 2018

@swift-ci please test

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - 9a3b232

@graydon
Copy link
Contributor Author

graydon commented Oct 21, 2018

Linux builds are failing for unrelated cmake-reasons; this patch passed linux integration on master and I see no way it could be risky, so merging now.

@graydon graydon merged commit 9cfd3c4 into swiftlang:swift-5.0-branch Oct 21, 2018
@jrose-apple
Copy link
Contributor

Oh, this is so much better. I didn't know about two-argument basename!

(I assume you also committed this to master?)

@graydon
Copy link
Contributor Author

graydon commented Oct 22, 2018

@jrose-apple yes in #19943

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants