File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,15 @@ module('Route | crate.range', function (hooks) {
78
78
assert . dom ( '[data-test-notification-message]' ) . doesNotExist ( ) ;
79
79
} ) ;
80
80
81
+ test ( 'shows an error page if crate not found' , async function ( assert ) {
82
+ await visit ( '/crates/foo/range/^3' ) ;
83
+ assert . equal ( currentURL ( ) , '/crates/foo/range/%5E3' ) ;
84
+ assert . dom ( '[data-test-404-page]' ) . exists ( ) ;
85
+ assert . dom ( '[data-test-title]' ) . hasText ( 'Crate not found' ) ;
86
+ assert . dom ( '[data-test-go-back]' ) . exists ( ) ;
87
+ assert . dom ( '[data-test-try-again]' ) . doesNotExist ( ) ;
88
+ } ) ;
89
+
81
90
test ( 'shows an error page if no match found' , async function ( assert ) {
82
91
let crate = this . server . create ( 'crate' , { name : 'foo' } ) ;
83
92
this . server . create ( 'version' , { crate, num : '1.0.0' } ) ;
You can’t perform that action at this time.
0 commit comments