@@ -56,8 +56,8 @@ describe('RBTree', function () {
56
56
var tree = new RBTree ( ) ;
57
57
tree . put ( 1 , 'bar' ) ;
58
58
tree . put ( 0 , 'baz' ) ;
59
- expect ( tree . _root . _left ) . not . toBeNull ( ) ;
60
- expect ( tree . _root . _left . isRed ( ) ) . toBeTruthy ( ) ;
59
+ expect ( tree . _root . getLeft ( ) ) . not . toBeNull ( ) ;
60
+ expect ( tree . _root . getLeft ( ) . isRed ( ) ) . toBeTruthy ( ) ;
61
61
tree . put ( 2 , 'baz' ) ;
62
62
expect ( tree . _root . getRight ( ) ) . not . toBeNull ( ) ;
63
63
expect ( tree . _root . getRight ( ) . isRed ( ) ) . toBeFalsy ( ) ;
@@ -67,10 +67,10 @@ describe('RBTree', function () {
67
67
tree . put ( 2 , 'foo' ) ;
68
68
tree . put ( 3 , 'baz' ) ;
69
69
expect ( tree . _root . getRight ( ) ) . not . toBeNull ( ) ;
70
- expect ( tree . _root . _left ) . not . toBeNull ( ) ;
70
+ expect ( tree . _root . getLeft ( ) ) . not . toBeNull ( ) ;
71
71
expect ( tree . _root . isRed ( ) ) . toBeFalsy ( ) ;
72
72
expect ( tree . _root . getRight ( ) . isRed ( ) ) . toBeFalsy ( ) ;
73
- expect ( tree . _root . _left . isRed ( ) ) . toBeFalsy ( ) ;
73
+ expect ( tree . _root . getLeft ( ) . isRed ( ) ) . toBeFalsy ( ) ;
74
74
tree . put ( 4 , 'foobar' ) ;
75
75
tree . put ( 5 , 'foobar' ) ;
76
76
expect ( tree . _root . getRight ( ) . getRight ( ) ) . not . toBeNull ( ) ;