File tree Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change 1+ /* the 'body' selector is required for the tests to pass */
2+ /* You can change the style attributes if you want */
3+ body {
4+ background-color : # 222 ;
5+ color : # ddd ;
6+ text-align : center;
7+ font-family : sans-serif;
8+ }
9+
10+ h1 {
11+ font-size : 4em ;
12+ }
13+
14+ input [type = "text" ],
15+ label {
16+ margin-bottom : 8px ;
17+ }
Original file line number Diff line number Diff line change @@ -13,6 +13,16 @@ describe("server", () => {
1313 assert . ok ( response . text . match ( / < ! D O C T Y P E h t m l > / ) ) ;
1414 } ) ;
1515 } ) ;
16+ // 4.1
17+ it ( "should load styled html thanks to express.static middleware allowing css to load" , ( ) => {
18+ return request ( server )
19+ . get ( "/style.css" )
20+ . expect ( "Content-type" , / c s s / )
21+ . expect ( 200 )
22+ . then ( response => {
23+ assert . ok ( response . text . match ( / b o d y { / ) ) ;
24+ } ) ;
25+ } ) ;
1626 after ( ( ) => {
1727 server . close ( ) ;
1828 } ) ;
You can’t perform that action at this time.
0 commit comments