diff options
| author | Lynx Linden <lynx@lindenlab.com> | 2010-01-15 00:40:36 +0000 | 
|---|---|---|
| committer | Lynx Linden <lynx@lindenlab.com> | 2010-01-15 00:40:36 +0000 | 
| commit | e7b69ec8f8a69a437f821fb1c6b6ebeea80e28cc (patch) | |
| tree | 0a1610fd78808c875196224d4fdfd1933cb134f2 /indra | |
| parent | 3b55ac4fbbee79533ce5952d326dad3ec071dd8b (diff) | |
| parent | 30c5d4477c3b731a50039850c7fcb52e9a59f32d (diff) | |
Automated merge with ssh://hg.lindenlab.com/viewer/viewer-2-0
Diffstat (limited to 'indra')
| -rw-r--r-- | indra/newview/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | indra/newview/tests/llviewerhelputil_test.cpp | 13 | 
2 files changed, 14 insertions, 1 deletions
| diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 923d4a52d3..b44f1a5c6c 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -1770,8 +1770,8 @@ else (LL_TESTS)      lldateutil.cpp      llmediadataclient.cpp      lllogininstance.cpp +    llviewerhelputil.cpp    ) -  # DISABLED TEST: llviewerhelputil.cpp /* not testing anything useful and hard to mock LLAgent dependency */    ##################################################    # DISABLING PRECOMPILED HEADERS USAGE FOR TESTS  diff --git a/indra/newview/tests/llviewerhelputil_test.cpp b/indra/newview/tests/llviewerhelputil_test.cpp index ec612c4606..d7dd199722 100644 --- a/indra/newview/tests/llviewerhelputil_test.cpp +++ b/indra/newview/tests/llviewerhelputil_test.cpp @@ -78,9 +78,21 @@ static void substitute_string(std::string &input, const std::string &search, con  	}  } +class LLAgent +{ +public: +	LLAgent() {} +	~LLAgent() {} +	BOOL isGodlike() const { return FALSE; } +private: +	int dummy; +}; +LLAgent gAgent; +  std::string LLWeb::expandURLSubstitutions(const std::string &url,  										  const LLSD &default_subs)  { +	(void)gAgent.isGodlike(); // ref symbol to stop compiler from stripping it  	std::string new_url = url;  	substitute_string(new_url, "[TOPIC]", default_subs["TOPIC"].asString());  	substitute_string(new_url, "[VERSION]", gVersion); @@ -91,6 +103,7 @@ std::string LLWeb::expandURLSubstitutions(const std::string &url,  	return new_url;  } +  //----------------------------------------------------------------------------  namespace tut | 
