Sent from my iPad
> On Feb 19, 2017, at 12:08 AM, Robert Widmann <[email protected]> wrote: > > @testable is already a hack. Why not just extend it to fileprivate members? That would be fine with me if others prefer that solution. It certainly leaves the rest of our code a lot cleaner. > > ~Robert Widmann > >> On Feb 18, 2017, at 1:14 PM, Matthew Johnson via swift-evolution >> <[email protected]> wrote: >> >> When writing unit tests sometimes it is necessary to artificially elevate a >> member to `internal` in order to make it visible to unit tests where it >> could otherwise be `private` or `fileprivate`. We could introduce an >> `@testable` attribute that could be applied anywhere an access modifier is >> used. This attribute would elevate the access modifier to `internal` when >> the module is imported using the `@testable import MyModule` syntax in a >> test suite. >> >> Is this something that others have interest in? Is it something that might >> be considered for Swift 4 now that phase 2 has begun? >> >> Matthew >> _______________________________________________ >> swift-evolution mailing list >> [email protected] >> https://lists.swift.org/mailman/listinfo/swift-evolution > _______________________________________________ swift-evolution mailing list [email protected] https://lists.swift.org/mailman/listinfo/swift-evolution
