diff UnitTestsSources/LuaTests.cpp @ 2363:f8ef157f2d73

fix unit tests given www.orthanc-server.com now mandatory uses HTTPS
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 21 Aug 2017 15:04:20 +0200
parents a3a65de1840f
children 883387e2b379
line wrap: on
line diff
--- a/UnitTestsSources/LuaTests.cpp	Mon Aug 21 13:53:29 2017 +0200
+++ b/UnitTestsSources/LuaTests.cpp	Mon Aug 21 15:04:20 2017 +0200
@@ -287,9 +287,15 @@
 {
   Orthanc::LuaContext lua;
 
-#if UNIT_TESTS_WITH_HTTP_CONNEXIONS == 1  
-  lua.Execute("JSON = loadstring(HttpGet('http://www.orthanc-server.com/downloads/third-party/JSON.lua')) ()");
-  const std::string url("http://www.orthanc-server.com/downloads/third-party/Product.json");
+#if UNIT_TESTS_WITH_HTTP_CONNEXIONS == 1
+  // It is not guaranteed that the URL on server
+  // "www.montefiore.ulg.ac.be" will work forever. We switched to it,
+  // as the "www.orthanc-server.com" now mandatory uses HTTPS.
+  const std::string BASE = "http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/";
+  //const std::string BASE = "http://www.orthanc-server.com/downloads/third-party/";
+
+  lua.Execute("JSON = loadstring(HttpGet('" + BASE + "JSON.lua')) ()");
+  const std::string url(BASE + "Product.json");
 #endif
 
   std::string s;