<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Pushkar,<div class=""><br class=""></div><div class="">Another option is to continue to use <a href="http://httpbin.org" class="">httpbin.org</a>, but make the tests that use that network service not part of the normal unit tests but runnable on demand by us as we develop. That means we don’t have to reimplement the whole thing but we at least have some tools at our disposal to help debug and diagnose issues. As we make fixes we can improve our local unit test server’s infrastructure to prevent regressions.</div><div class=""><br class=""></div><div class="">- Tony</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Mar 9, 2017, at 7:02 AM, Pushkar N Kulkarni <<a href="mailto:pushkar.nk@in.ibm.com" class="">pushkar.nk@in.ibm.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><font face="Verdana,Arial,Helvetica,sans-serif" size="2" class=""><div class="">Hi Tony, </div><div class=""><br class=""></div><div class="">PRs 911 and 913 reminded me of this conversation you started. </div><div class=""><br class=""></div><div class="">The current unit testing infrastructure for URLSession may prove insufficient for future contributions. I've been looking at these <a target="_blank" href="https://github.com/mike-ferenduros/swift-corelibs-foundation/blob/more-urlsession-tests/TestFoundation/TestNSURLSession.swift" title="https://github.com/mike-ferenduros/swift-corelibs-foundation/blob/more-urlsession-tests/TestFoundation/TestNSURLSession.swift " class="">tests</a> written by Mike Ferenduros and they appear quite exhaustive! The only issue is that they connect to an external HTTP test service - <a href="http://httpbin.org./" target="_blank" class="">http://httpbin.org.</a> </div><div class=""><br class=""></div><div class="">A quick look at <a href="http://httpbin.org" class="">httpbin.org</a> tells me it has sufficient functionality to aid in URLSession unit testing. Do you think it would make sense to emulate this functionality within TestFoundation?</div><div class=""><br class=""></div><div class=""><font face="Verdana,Arial,Helvetica,sans-serif" size="2" class=""><font class=""><font class=""><div class="socmaildefaultfont" dir="ltr"><div class="socmaildefaultfont" dir="ltr"><div class="socmaildefaultfont" dir="ltr"><div dir="ltr" style="font-style: normal;" class=""><br class=""><font face="Sans Serif, Verdana, Arial, Helvetica, sans-serif" class="">Pushkar N Kulkarni,</font></div>
<div dir="ltr" style="font-style: normal;" class=""><font face="Sans Serif, Verdana, Arial, Helvetica, sans-serif" class="">IBM Runtimes</font></div><div dir="ltr" style="font-style: normal;" class=""><font face="Sans Serif, Verdana, Arial, Helvetica, sans-serif" class=""><br class=""></font></div><div dir="ltr" class=""><font face="serif, Times New Roman, Times, serif" class=""><i class="">Simplicity is prerequisite for reliability - Edsger W. Dijkstra</i></font></div>
<div dir="ltr" style="font-style: normal; font-size: 10.5pt; font-family: Arial;" class=""><br class=""></div></div></div></div></font></font></font></div><br class=""><br class=""><font face="Default Sans Serif,Verdana,Arial,Helvetica,sans-serif" size="2" class=""><font color="#990099" class=""><a href="mailto:-----swift-corelibs-dev-bounces@swift.org" target="_blank" class="">-----swift-corelibs-dev-bounces@swift.org</a> wrote: -----</font><div class="iNotesHistory" style="padding-left:5px;"><div style="padding-right:0px;padding-left:5px;border-left:solid black 2px;" class="">To: swift-corelibs-dev <<a href="mailto:swift-corelibs-dev@swift.org" target="_blank" class="">swift-corelibs-dev@swift.org</a>><br class="">From: Tony Parker via swift-corelibs-dev <swift-corelibs-dev@swift.org class=""><br class="">Sent by: <a href="mailto:swift-corelibs-dev-bounces@swift.org" target="_blank" class="">swift-corelibs-dev-bounces@swift.org</a><br class="">Date: 01/25/2017 01:13AM<br class="">Subject: [swift-corelibs-dev] URLSession test fest!<br class=""><br class=""><div class=""><font face="Courier New,Courier,monospace" size="3" class="">Hi everyone,<br class=""><br class="">As we’re wrapping up Swift 3.1, I think it’d be a great opportunity to have a quality focus area on one of our most important APIs: URLSession. If you’ve been wondering how to make a meaningful contribution, this is the perfect time.<br class=""><br class="">It’d be great to greatly expand both unit test and higher level test coverage of URLSession. For testing that can’t really be part of a unit test and CI like poorly performing networks or esoteric configurations, it would also be nice to build a different kind of test tool. That tool would provide a lot of knobs for controlling a URLSession. We could make this tool part of the swift-corelibs-foundation project.<br class=""><br class="">Is anyone interested in chipping in here? We don’t have to start big. Even small contributions could get us moving in the right direction.<br class=""><br class="">Thanks,<br class="">- Tony<br class=""><br class=""><br class=""><br class="">_______________________________________________<br class="">swift-corelibs-dev mailing list<br class=""><a href="mailto:swift-corelibs-dev@swift.org" target="_blank" class="">swift-corelibs-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</a><br class=""></font></div></swift-corelibs-dev@swift.org></div></div></font></font><br class="">
</div></blockquote></div><br class=""></div></body></html>