@@ -54,7 +54,7 @@ test('readability', function (t) {
5454
5555 retext ( )
5656 . use ( readability , {
57- 'age ' : 18
57+ 'threshold ' : 5 / 7
5858 } )
5959 . process ( [
6060 'Oberon, also designated Uranus IV, is the outermost ' ,
@@ -64,6 +64,25 @@ test('readability', function (t) {
6464 ] . join ( '\n' ) , function ( err , file ) {
6565 t . ifError ( err , 'should not fail (#3)' ) ;
6666
67+ t . deepEqual (
68+ file . messages . map ( String ) ,
69+ [ ] ,
70+ 'should support a threshold'
71+ ) ;
72+ } ) ;
73+
74+ retext ( )
75+ . use ( readability , {
76+ 'age' : 18
77+ } )
78+ . process ( [
79+ 'Oberon, also designated Uranus IV, is the outermost ' ,
80+ 'major moon of the planet Uranus and quite large' ,
81+ 'and massive for a Uranian moon.' ,
82+ ''
83+ ] . join ( '\n' ) , function ( err , file ) {
84+ t . ifError ( err , 'should not fail (#4)' ) ;
85+
6786 t . deepEqual (
6887 file . messages . map ( String ) ,
6988 [ ] ,
@@ -81,7 +100,7 @@ test('readability', function (t) {
81100 'and massive for a Uranian moon.' ,
82101 ''
83102 ] . join ( '\n' ) , function ( err , file ) {
84- t . ifError ( err , 'should not fail (#4 )' ) ;
103+ t . ifError ( err , 'should not fail (#5 )' ) ;
85104
86105 t . deepEqual (
87106 file . messages . map ( String ) ,
@@ -98,7 +117,7 @@ test('readability', function (t) {
98117 'and second most massive of the Uranian moons.' ,
99118 ''
100119 ] . join ( '\n' ) , function ( err , file ) {
101- t . ifError ( err , 'should not fail (#5 )' ) ;
120+ t . ifError ( err , 'should not fail (#6 )' ) ;
102121
103122 t . deepEqual (
104123 file . messages . map ( String ) ,
@@ -118,7 +137,7 @@ test('readability', function (t) {
118137 'ninth most massive moon in the Solar System.' ,
119138 ''
120139 ] . join ( '\n' ) , function ( err , file ) {
121- t . ifError ( err , 'should not fail (#6 )' ) ;
140+ t . ifError ( err , 'should not fail (#7 )' ) ;
122141
123142 t . deepEqual (
124143 file . messages . map ( String ) ,
0 commit comments