Mercurial > hg > orthanc
comparison UnitTestsSources/LuaTests.cpp @ 1396:ac4efabeb80c
Migration of the orthanc-client as a separate project
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 01 Jun 2015 11:15:55 +0200 |
parents | 6e7e5ed91c2d |
children | 354640db5a7f |
comparison
equal
deleted
inserted
replaced
1395:785e01da36a1 | 1396:ac4efabeb80c |
---|---|
242 { | 242 { |
243 Orthanc::LuaContext lua; | 243 Orthanc::LuaContext lua; |
244 | 244 |
245 #if UNIT_TESTS_WITH_HTTP_CONNEXIONS == 1 | 245 #if UNIT_TESTS_WITH_HTTP_CONNEXIONS == 1 |
246 lua.Execute("JSON = loadstring(HttpGet('http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/JSON.lua')) ()"); | 246 lua.Execute("JSON = loadstring(HttpGet('http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/JSON.lua')) ()"); |
247 const std::string url("http://orthanc.googlecode.com/hg/OrthancCppClient/SharedLibrary/Product.json"); | 247 const std::string url("http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/Product.json"); |
248 #endif | 248 #endif |
249 | 249 |
250 std::string s; | 250 std::string s; |
251 lua.Execute(s, "print(HttpGet({}))"); | 251 lua.Execute(s, "print(HttpGet({}))"); |
252 ASSERT_EQ("ERROR", Orthanc::Toolbox::StripSpaces(s)); | 252 ASSERT_EQ("ERROR", Orthanc::Toolbox::StripSpaces(s)); |