diff options
| author | jsmall-nvidia <jsmall@nvidia.com> | 2023-04-25 10:43:29 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-25 10:43:29 -0400 |
| commit | 7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0 (patch) | |
| tree | 9c71955dbc956b0058b19818ca127c8132cda512 /tools/slang-test/slang-test-main.cpp | |
| parent | 284cee1f246c072f190c87c8fb60c1d2181e458f (diff) | |
Dictionary using lowerCamel (#2835)
* #include an absolute path didn't work - because paths were taken to always be relative.
* WIP lowerCamel Dictionary.
* WIP more lowerCamel fixes for Dictionary.
* Add/Remove/Clear
* GetValue/Contains
* Fix tabs in dictionary.
Count -> getCount
* Fix fields with caps.
* Key -> key
Value -> value
Use m_ for members where appropriate.
Use lowerCamel in linked list.
* Some small fixes/improvements to Dictionary.
* Kick CI.
Diffstat (limited to 'tools/slang-test/slang-test-main.cpp')
| -rw-r--r-- | tools/slang-test/slang-test-main.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/tools/slang-test/slang-test-main.cpp b/tools/slang-test/slang-test-main.cpp index 739ea840e..94329831b 100644 --- a/tools/slang-test/slang-test-main.cpp +++ b/tools/slang-test/slang-test-main.cpp @@ -82,11 +82,11 @@ struct TestOptions // Small helper to help consistently interrogating for filecheck usage bool getFileCheckPrefix(String& prefix) const { - return commandOptions.TryGetValue("filecheck", prefix); + return commandOptions.tryGetValue("filecheck", prefix); } bool getFileCheckBufferPrefix(String& prefix) const { - return commandOptions.TryGetValue("filecheck-buffer", prefix); + return commandOptions.tryGetValue("filecheck-buffer", prefix); } Type type = Type::Normal; @@ -160,7 +160,7 @@ static SlangResult _readTestFile(const TestInput& input, const String& suffix, S return r; } - buf.Clear(); + buf.clear(); buf << input.filePath << suffix; return Slang::File::readAllText(buf, out); } @@ -335,11 +335,11 @@ static SlangResult _parseCommandArguments(char const** ioCursor, TestOptions& ou auto i = option.indexOf('='); if(i == -1) { - out.commandOptions.Add(option.trim(), ""); + out.commandOptions.add(option.trim(), ""); } else { - out.commandOptions.Add(option.head(i).trim(), option.tail(i+1).trim()); + out.commandOptions.add(option.head(i).trim(), option.tail(i+1).trim()); } } } @@ -1345,7 +1345,7 @@ String findExpectedPath(const TestInput& input, const char* postFix) // Try the default name StringBuilder defaultBuf; - defaultBuf.Clear(); + defaultBuf.clear(); defaultBuf << input.filePath; if (postFix) { @@ -3610,7 +3610,7 @@ bool testCategoryMatches( { for( auto item : categorySet ) { - if(testCategoryMatches(categoryToMatch, item.Value)) + if(testCategoryMatches(categoryToMatch, item.value)) return true; } return false; @@ -4381,15 +4381,15 @@ SlangResult innerMain(int argc, char** argv) return func(StdWriters::getSingleton(), context.getSession(), int(args.getCount()), args.getBuffer()); } - if( options.includeCategories.Count() == 0 ) + if( options.includeCategories.getCount() == 0 ) { - options.includeCategories.Add(fullTestCategory, fullTestCategory); + options.includeCategories.add(fullTestCategory, fullTestCategory); } // Don't include OptiX tests unless the client has explicit opted into them. - if( !options.includeCategories.ContainsKey(optixTestCategory) ) + if( !options.includeCategories.containsKey(optixTestCategory) ) { - options.excludeCategories.Add(optixTestCategory, optixTestCategory); + options.excludeCategories.add(optixTestCategory, optixTestCategory); } // Exclude rendering tests when building under AppVeyor. @@ -4397,8 +4397,8 @@ SlangResult innerMain(int argc, char** argv) // TODO: this is very ad hoc, and we should do something cleaner. if( options.outputMode == TestOutputMode::AppVeyor ) { - options.excludeCategories.Add(renderTestCategory, renderTestCategory); - options.excludeCategories.Add(vulkanTestCategory, vulkanTestCategory); + options.excludeCategories.add(renderTestCategory, renderTestCategory); + options.excludeCategories.add(vulkanTestCategory, vulkanTestCategory); } { |
