diff --git a/main.cpp b/main.cpp
index a343682..ebf886f 100644
--- a/main.cpp
+++ b/main.cpp
@@ -9,10 +9,15 @@
 void printResult(const QString &test, bool shouldBe, const MatchResult &result) {
     if (result.success != shouldBe) {
         g_numFailed++;
-        qDebug() << "TEST FAILS:";
+        qDebug() << "\nTEST FAILS:";
+        qDebug() << "with context" << result.context;
     }
 
     qDebug() << "MatchResult" << test << result.success;
+
+    if (result.success != shouldBe) {
+        qDebug() << "";
+    }
 }
 
 int testResults() {
@@ -28,6 +33,8 @@
 void runTests() {
     printResult("a = a", true, match({Token('a')}, {Token('a')}, VarContext()));
 
+    printResult("s.a = y", true, match({Token('y')}, {Token('s', "a")}, VarContext()));
+
     LTok sameTwo = {Token('s', "a"), Token('s', "a")};
     printResult("s.a s.a = aa", true, match({Token('a'), Token('a')}, sameTwo, VarContext()));
     printResult("s.a s.a = ab", false, match({Token('a'), Token('b')}, sameTwo, VarContext()));
@@ -51,6 +58,28 @@
                 match({
                               Token('a'), Token('e'), Token('f'), Token("Hi"), Token('c')
                       }, sameStartEnd, VarContext()));
+
+    LTok parenthesized = {
+            Token(LTok({
+                               Token('s', "a")
+                       })),
+            Token('e', "Middle"),
+            Token('s', "a"),
+    };
+    LTok parenTest1 = {
+            Token(LTok({
+                               Token('y')
+                       })),
+            Token('f'),
+            Token("MiddleStuff"),
+            Token('y')
+    };
+
+    printResult("(s.a) e.Middle s.a = (y)f MiddleStuff y", true,
+                match(parenTest1, parenthesized, VarContext()));
+
+    printResult("(a) = (a)", true,
+                match({Token({Token('a')})}, {Token({Token('a')})}, VarContext()));
 }
 
 int main(int argc, char *argv[]) {
