@@ -33,8 +33,6 @@ async fn non_interactive_basic_init() {
3333 assert ! ( cargo_toml. contains( "shuttle-runtime = " ) ) ;
3434}
3535
36- // TODO: unignore when shuttle-rocket is published
37- #[ ignore]
3836#[ tokio:: test]
3937async fn non_interactive_rocket_init ( ) {
4038 let temp_dir = Builder :: new ( ) . prefix ( "rocket-init" ) . tempdir ( ) . unwrap ( ) ;
@@ -57,8 +55,6 @@ async fn non_interactive_rocket_init() {
5755 assert_valid_rocket_project ( temp_dir_path. as_path ( ) , "rocket-init" ) ;
5856}
5957
60- // TODO: unignore when shuttle-rocket is published
61- #[ ignore]
6258#[ test]
6359fn interactive_rocket_init ( ) -> Result < ( ) , Box < dyn std:: error:: Error > > {
6460 let temp_dir = Builder :: new ( ) . prefix ( "rocket-init" ) . tempdir ( ) . unwrap ( ) ;
@@ -98,8 +94,6 @@ fn interactive_rocket_init() -> Result<(), Box<dyn std::error::Error>> {
9894 Ok ( ( ) )
9995}
10096
101- // TODO: unignore when shuttle-rocket is published
102- #[ ignore]
10397#[ test]
10498fn interactive_rocket_init_dont_prompt_framework ( ) -> Result < ( ) , Box < dyn std:: error:: Error > > {
10599 let temp_dir = Builder :: new ( ) . prefix ( "rocket-init" ) . tempdir ( ) . unwrap ( ) ;
@@ -135,8 +129,6 @@ fn interactive_rocket_init_dont_prompt_framework() -> Result<(), Box<dyn std::er
135129 Ok ( ( ) )
136130}
137131
138- // TODO: unignore when shuttle-rocket is published
139- #[ ignore]
140132#[ test]
141133fn interactive_rocket_init_dont_prompt_name ( ) -> Result < ( ) , Box < dyn std:: error:: Error > > {
142134 let temp_dir = Builder :: new ( ) . prefix ( "rocket-init" ) . tempdir ( ) . unwrap ( ) ;
@@ -176,11 +168,10 @@ fn interactive_rocket_init_dont_prompt_name() -> Result<(), Box<dyn std::error::
176168fn assert_valid_rocket_project ( path : & Path , name_prefix : & str ) {
177169 let cargo_toml = read_to_string ( path. join ( "Cargo.toml" ) ) . unwrap ( ) ;
178170 assert ! ( cargo_toml. contains( & format!( "name = \" {name_prefix}" ) ) ) ;
179- assert ! ( cargo_toml. contains( "shuttle-service = { version = " ) ) ;
180- assert ! ( cargo_toml. contains( "features = [\" web-rocket\" ]" ) ) ;
181- assert ! ( cargo_toml. contains( "rocket = " ) ) ;
171+ assert ! ( cargo_toml. contains( "shuttle-runtime = " ) ) ;
172+ assert ! ( cargo_toml. contains( "shuttle-rocket = " ) ) ;
182173
183- let lib_file = read_to_string ( path. join ( "src" ) . join ( "lib .rs" ) ) . unwrap ( ) ;
174+ let main_file = read_to_string ( path. join ( "src" ) . join ( "main .rs" ) ) . unwrap ( ) ;
184175 let expected = indoc ! { r#"
185176 #[macro_use]
186177 extern crate rocket;
@@ -190,12 +181,12 @@ fn assert_valid_rocket_project(path: &Path, name_prefix: &str) {
190181 "Hello, world!"
191182 }
192183
193- #[shuttle_service ::main]
194- async fn rocket() -> shuttle_service ::ShuttleRocket {
184+ #[shuttle_runtime ::main]
185+ async fn rocket() -> shuttle_rocket ::ShuttleRocket {
195186 let rocket = rocket::build().mount("/hello", routes![index]);
196187
197- Ok(rocket)
188+ Ok(rocket.into() )
198189 }"# } ;
199190
200- assert_eq ! ( lib_file , expected) ;
191+ assert_eq ! ( main_file , expected) ;
201192}
0 commit comments