gem5  v20.1.0.0
Functions
str.test.cc File Reference
#include <gtest/gtest.h>
#include <cstdint>
#include "base/str.hh"

Go to the source code of this file.

Functions

 TEST (StrTest, EatLeadWhite)
 
 TEST (StrTest, EatLeadWhiteNoLeadingWhitespace)
 
 TEST (StrTest, EatEndWhite)
 
 TEST (StrTest, EatEndWhiteNoTrailingWhitespace)
 
 TEST (StrTest, EatWhite)
 
 TEST (StrTest, EatWhiteNoWhitespace)
 
 TEST (StrTest, ToLower)
 
 TEST (StrTest, SplitFirst)
 
 TEST (StrTest, SplitFirstNoChar)
 
 TEST (StrTest, SplitFirstOnFirstChar)
 
 TEST (StrTest, SplitLast)
 
 TEST (StrTest, SplitLastNoChar)
 
 TEST (StrTest, SplitLastOnLastChar)
 
 TEST (StrTest, TokenizeOnSpace)
 
 TEST (StrTest, TokenizeOnSpaceIgnFalse)
 
 TEST (StrTest, TokenizedTokenDoesNotExist)
 
 TEST (StrTest, ToNumber8BitInt)
 
 TEST (StrTest, ToNumber8BitIntStringOutOfRange)
 
 TEST (StrTest, ToNumber8BitIntInvalidString)
 
 TEST (StrTest, ToNumberUnsigned8BitInt)
 
 TEST (StrTest, ToNumberUnsigned8BitIntNegative)
 
 TEST (StrTest, ToNumber64BitInt)
 
 TEST (StrTest, ToNumber64BitIntInvalidString)
 
 TEST (StrTest, ToNumberFloat)
 
 TEST (StrTest, ToNumberFloatIntegerString)
 
 TEST (StrTest, ToNumberFloatNegative)
 
 TEST (StrTest, ToNumberDouble)
 
 TEST (StrTest, ToNumberDoubleIntegerString)
 
 TEST (StrTest, ToNumberDoubleNegative)
 
 TEST (StrTest, ToBoolTrue)
 
 TEST (StrTest, ToBoolFalse)
 
 TEST (StrTest, ToBoolInvalidInput)
 
 TEST (StrTest, QuoteStringNoSpace)
 
 TEST (StrTest, QuoteStringWithSpace)
 
 TEST (StrTest, QuoteQuotedString)
 
 TEST (StrTest, QuoteStringWithTab)
 
 TEST (StrTest, StartswithDoubleStringDoesStartWith)
 
 TEST (StrTest, StartswithDoubleStringDoesNotStartWith)
 
 TEST (StrTest, StartswithDoubleCharArrayDoesStartWith)
 
 TEST (StrTest, StartswithDoubleCharArrayDoesNotStartWith)
 
 TEST (StrTest, StartswithStringCharArrayDoesStartWith)
 
 TEST (StrTest, StartswithStringCharArrayDoesNotStartWith)
 

Function Documentation

◆ TEST() [1/42]

TEST ( StrTest  ,
EatEndWhite   
)

Definition at line 63 of file str.test.cc.

References eat_end_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [2/42]

TEST ( StrTest  ,
EatEndWhiteNoTrailingWhitespace   
)

Definition at line 70 of file str.test.cc.

References eat_end_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [3/42]

TEST ( StrTest  ,
EatLeadWhite   
)

Definition at line 49 of file str.test.cc.

References eat_lead_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [4/42]

TEST ( StrTest  ,
EatLeadWhiteNoLeadingWhitespace   
)

Definition at line 56 of file str.test.cc.

References eat_lead_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [5/42]

TEST ( StrTest  ,
EatWhite   
)

Definition at line 77 of file str.test.cc.

References eat_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [6/42]

TEST ( StrTest  ,
EatWhiteNoWhitespace   
)

Definition at line 84 of file str.test.cc.

References eat_lead_white(), EXPECT_EQ, and X86ISA::val.

◆ TEST() [7/42]

TEST ( StrTest  ,
QuoteQuotedString   
)

Definition at line 396 of file str.test.cc.

References EXPECT_EQ, and quote().

◆ TEST() [8/42]

TEST ( StrTest  ,
QuoteStringNoSpace   
)

Definition at line 386 of file str.test.cc.

References EXPECT_EQ, and quote().

◆ TEST() [9/42]

TEST ( StrTest  ,
QuoteStringWithSpace   
)

Definition at line 391 of file str.test.cc.

References EXPECT_EQ, and quote().

◆ TEST() [10/42]

TEST ( StrTest  ,
QuoteStringWithTab   
)

Definition at line 404 of file str.test.cc.

References EXPECT_EQ, and quote().

◆ TEST() [11/42]

TEST ( StrTest  ,
SplitFirst   
)

Definition at line 110 of file str.test.cc.

References EXPECT_EQ, split_first(), and X86ISA::val.

◆ TEST() [12/42]

TEST ( StrTest  ,
SplitFirstNoChar   
)

Definition at line 122 of file str.test.cc.

References EXPECT_EQ, split_first(), and X86ISA::val.

◆ TEST() [13/42]

TEST ( StrTest  ,
SplitFirstOnFirstChar   
)

Definition at line 134 of file str.test.cc.

References EXPECT_EQ, split_first(), and X86ISA::val.

◆ TEST() [14/42]

TEST ( StrTest  ,
SplitLast   
)

Definition at line 146 of file str.test.cc.

References EXPECT_EQ, split_last(), and X86ISA::val.

◆ TEST() [15/42]

TEST ( StrTest  ,
SplitLastNoChar   
)

Definition at line 158 of file str.test.cc.

References EXPECT_EQ, split_last(), and X86ISA::val.

◆ TEST() [16/42]

TEST ( StrTest  ,
SplitLastOnLastChar   
)

Definition at line 170 of file str.test.cc.

References EXPECT_EQ, split_last(), and X86ISA::val.

◆ TEST() [17/42]

TEST ( StrTest  ,
StartswithDoubleCharArrayDoesNotStartWith   
)

Definition at line 440 of file str.test.cc.

References EXPECT_FALSE, ArmISA::s, and startswith().

◆ TEST() [18/42]

TEST ( StrTest  ,
StartswithDoubleCharArrayDoesStartWith   
)

Definition at line 433 of file str.test.cc.

References EXPECT_TRUE, ArmISA::s, and startswith().

◆ TEST() [19/42]

TEST ( StrTest  ,
StartswithDoubleStringDoesNotStartWith   
)

Definition at line 426 of file str.test.cc.

References EXPECT_FALSE, ArmISA::s, and startswith().

◆ TEST() [20/42]

TEST ( StrTest  ,
StartswithDoubleStringDoesStartWith   
)

Definition at line 419 of file str.test.cc.

References EXPECT_TRUE, ArmISA::s, and startswith().

◆ TEST() [21/42]

TEST ( StrTest  ,
StartswithStringCharArrayDoesNotStartWith   
)

Definition at line 454 of file str.test.cc.

References EXPECT_FALSE, ArmISA::s, and startswith().

◆ TEST() [22/42]

TEST ( StrTest  ,
StartswithStringCharArrayDoesStartWith   
)

Definition at line 447 of file str.test.cc.

References EXPECT_TRUE, ArmISA::s, and startswith().

◆ TEST() [23/42]

TEST ( StrTest  ,
ToBoolFalse   
)

Definition at line 370 of file str.test.cc.

References EXPECT_FALSE, EXPECT_TRUE, output(), and to_bool().

◆ TEST() [24/42]

TEST ( StrTest  ,
ToBoolInvalidInput   
)

Definition at line 376 of file str.test.cc.

References EXPECT_FALSE, output(), and to_bool().

◆ TEST() [25/42]

TEST ( StrTest  ,
ToBoolTrue   
)

Definition at line 363 of file str.test.cc.

References EXPECT_TRUE, output(), and to_bool().

◆ TEST() [26/42]

TEST ( StrTest  ,
TokenizedTokenDoesNotExist   
)

Definition at line 235 of file str.test.cc.

References EXPECT_EQ, tokenize(), and X86ISA::val.

◆ TEST() [27/42]

TEST ( StrTest  ,
TokenizeOnSpace   
)

Definition at line 187 of file str.test.cc.

References EXPECT_EQ, tokenize(), and X86ISA::val.

◆ TEST() [28/42]

TEST ( StrTest  ,
TokenizeOnSpaceIgnFalse   
)

Definition at line 210 of file str.test.cc.

References EXPECT_EQ, tokenize(), and X86ISA::val.

◆ TEST() [29/42]

TEST ( StrTest  ,
ToLower   
)

Definition at line 95 of file str.test.cc.

References EXPECT_EQ, to_lower(), and X86ISA::val.

◆ TEST() [30/42]

TEST ( StrTest  ,
ToNumber64BitInt   
)

Definition at line 288 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), to_number(), and sc_dt::to_string().

◆ TEST() [31/42]

TEST ( StrTest  ,
ToNumber64BitIntInvalidString   
)

Definition at line 297 of file str.test.cc.

References EXPECT_FALSE, output(), and to_number().

◆ TEST() [32/42]

TEST ( StrTest  ,
ToNumber8BitInt   
)

Definition at line 251 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [33/42]

TEST ( StrTest  ,
ToNumber8BitIntInvalidString   
)

Definition at line 266 of file str.test.cc.

References EXPECT_FALSE, output(), and to_number().

◆ TEST() [34/42]

TEST ( StrTest  ,
ToNumber8BitIntStringOutOfRange   
)

Definition at line 259 of file str.test.cc.

References EXPECT_FALSE, output(), and to_number().

◆ TEST() [35/42]

TEST ( StrTest  ,
ToNumberDouble   
)

Definition at line 331 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [36/42]

TEST ( StrTest  ,
ToNumberDoubleIntegerString   
)

Definition at line 340 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [37/42]

TEST ( StrTest  ,
ToNumberDoubleNegative   
)

Definition at line 349 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [38/42]

TEST ( StrTest  ,
ToNumberFloat   
)

Definition at line 304 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [39/42]

TEST ( StrTest  ,
ToNumberFloatIntegerString   
)

Definition at line 313 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [40/42]

TEST ( StrTest  ,
ToNumberFloatNegative   
)

Definition at line 322 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [41/42]

TEST ( StrTest  ,
ToNumberUnsigned8BitInt   
)

Definition at line 273 of file str.test.cc.

References EXPECT_EQ, EXPECT_TRUE, output(), and to_number().

◆ TEST() [42/42]

TEST ( StrTest  ,
ToNumberUnsigned8BitIntNegative   
)

Definition at line 281 of file str.test.cc.

References EXPECT_FALSE, output(), and to_number().


Generated on Wed Sep 30 2020 14:02:18 for gem5 by doxygen 1.8.17