mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-22 20:23:09 +02:00
Unit Tests
- Modified Lexer types to reflect DOM recognition.
This commit is contained in:
parent
237d932ff9
commit
234e4d7308
1 changed files with 3 additions and 3 deletions
|
@ -98,8 +98,8 @@ int main (int argc, char** argv)
|
|||
tokens.push_back (std::pair <std::string, Lexer::Type> (token, type));
|
||||
}
|
||||
|
||||
t.is (tokens[0].first, "one", "tokens[0] = 'left'"); // 30
|
||||
t.is (Lexer::typeName (tokens[0].second), "identifier", "tokens[0] = identifier");
|
||||
t.is (tokens[0].first, "one", "tokens[0] = 'one'"); // 30
|
||||
t.is (Lexer::typeName (tokens[0].second), "dom", "tokens[0] = dom");
|
||||
|
||||
t.is (tokens[1].first, "'two 'three''", "tokens[1] = 'two 'three''");
|
||||
t.is (Lexer::typeName (tokens[1].second), "string", "tokens[1] = string");
|
||||
|
@ -138,7 +138,7 @@ int main (int argc, char** argv)
|
|||
t.is (Lexer::typeName (tokens[12].second), "number", "tokens[12] = number");
|
||||
|
||||
t.is (tokens[13].first, "foo.bar", "tokens[13] = 'foo.bar'");
|
||||
t.is (Lexer::typeName (tokens[13].second), "identifier", "tokens[13] = identifier");
|
||||
t.is (Lexer::typeName (tokens[13].second), "dom", "tokens[13] = dom");
|
||||
|
||||
t.is (tokens[14].first, "and", "tokens[14] = 'and'"); // 60
|
||||
t.is (Lexer::typeName (tokens[14].second), "op", "tokens[14] = op");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue