#include "squid.h"#include "base/CharacterSet.h"#include "base/TextException.h"#include "compat/cppunit.h"#include "event.h"#include "HttpReply.h"#include "MemObject.h"#include "sbuf/Algorithms.h"#include "sbuf/SBuf.h"#include "sbuf/Stream.h"#include "tests/SBufFindTest.h"#include "unitTestMain.h"#include <iostream>#include <stdexcept>#include <unordered_map>
Go to the source code of this file.
Classes | |
| class | TestSBuf |
| class | SBufSubstrAutoTest |
Functions | |
| CPPUNIT_TEST_SUITE_REGISTRATION (TestSBuf) | |
| void | eventAdd (const char *, EVH *, void *, double, int, bool) |
| static int | sign (int v) |
| static void | testComparisonStdFull (const char *left, const char *right) |
| static void | testComparisonStdN (const char *left, const char *right, const size_t n) |
| static void | testComparisonStdOneWay (const char *left, const char *right) |
| static void | testComparisonStd (const char *s1, const char *s2) |
| int | main (int argc, char *argv[]) |
Variables | |
| static const char | fox [] = "The quick brown fox jumped over the lazy dog" |
| static const char | fox1 [] = "The quick brown fox " |
| static const char | fox2 [] = "jumped over the lazy dog" |
| SBuf | empty_sbuf |
| SBuf | literal ("The quick brown fox jumped over the lazy dog") |
Function Documentation
◆ CPPUNIT_TEST_SUITE_REGISTRATION()
| CPPUNIT_TEST_SUITE_REGISTRATION | ( | TestSBuf | ) |
◆ eventAdd()
Definition at line 114 of file testSBuf.cc.
◆ main()
Definition at line 1194 of file testSBuf.cc.
References TestProgram::run().
◆ sign()
Definition at line 339 of file testSBuf.cc.
Referenced by TestSBuf::testComparisons(), testComparisonStdFull(), and testComparisonStdN().
◆ testComparisonStd()
|
static |
Definition at line 399 of file testSBuf.cc.
References s1, and testComparisonStdOneWay().
Referenced by TestSBuf::testComparisons().
◆ testComparisonStdFull()
|
static |
Definition at line 349 of file testSBuf.cc.
References sign().
Referenced by testComparisonStdOneWay().
◆ testComparisonStdN()
|
static |
Definition at line 369 of file testSBuf.cc.
References sign().
Referenced by testComparisonStdOneWay().
◆ testComparisonStdOneWay()
|
static |
Definition at line 389 of file testSBuf.cc.
References min(), testComparisonStdFull(), and testComparisonStdN().
Referenced by TestSBuf::testComparisons(), and testComparisonStd().
Variable Documentation
◆ empty_sbuf
| SBuf empty_sbuf |
Definition at line 129 of file testSBuf.cc.
Referenced by TestSBuf::testSBufConstructDestruct().
◆ fox
|
static |
Definition at line 122 of file testSBuf.cc.
Referenced by TestSBuf::testAppendf(), TestSBuf::testEqualityTest(), TestSBuf::testRawContent(), TestSBuf::testReserve(), TestSBuf::testSBufConstructDestruct(), TestSBuf::testSBufHash(), and TestSBuf::testSBufLength().
◆ fox1
|
static |
Definition at line 123 of file testSBuf.cc.
Referenced by TestSBuf::testAppendCString(), TestSBuf::testAppendSBuf(), TestSBuf::testCopy(), TestSBuf::testRawSpace(), TestSBuf::testSBufHash(), TestSBuf::testSBufStream(), and TestSBuf::testStartsWith().
◆ fox2
|
static |
Definition at line 124 of file testSBuf.cc.
Referenced by TestSBuf::testAppendCString(), TestSBuf::testRawSpace(), TestSBuf::testSBufStream(), and TestSBuf::testStartsWith().
◆ literal
| SBuf literal("The quick brown fox jumped over the lazy dog") | ( | "The quick brown fox jumped over the lazy dog" | ) |
Referenced by TestSBuf::testAppendCString(), TestSBuf::testChop(), TestSBuf::testConsume(), TestSBuf::testCopy(), TestSBuf::testFindFirstNotOf(), TestSBuf::testFindFirstOf(), TestSBuf::testGrow(), TestSBuf::testRawContent(), TestSBuf::testRawSpace(), TestSBuf::testRFindChar(), TestSBuf::testRFindSBuf(), TestSBuf::testSBufConstructDestruct(), TestSBuf::testSBufHash(), TestSBuf::testSBufStream(), TestSBuf::testStartsWith(), TestSBuf::testStringOps(), TestSBuf::testSubscriptOp(), TestSBuf::testSubscriptOpFail(), and TestSBuf::testSubstr().
