Skip to content

Commit

Permalink
test(embedded): Migrate to new syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
epage committed Sep 16, 2023
1 parent d064701 commit 46ad13b
Showing 1 changed file with 15 additions and 19 deletions.
34 changes: 15 additions & 19 deletions tests/testsuite/script.rs
Original file line number Diff line number Diff line change
Expand Up @@ -208,11 +208,10 @@ error: running `echo.rs` requires `-Zscript`
#[cargo_test]
fn clean_output_with_edition() {
let script = r#"#!/usr/bin/env cargo
//! ```cargo
//! [package]
//! edition = "2018"
//! ```
```cargo
[package]
edition = "2018"
```
fn main() {
println!("Hello world!");
Expand Down Expand Up @@ -240,10 +239,9 @@ fn main() {
#[cargo_test]
fn warning_without_edition() {
let script = r#"#!/usr/bin/env cargo
//! ```cargo
//! [package]
//! ```
```cargo
[package]
```
fn main() {
println!("Hello world!");
Expand Down Expand Up @@ -625,11 +623,10 @@ fn missing_script_rs() {
fn test_name_same_as_dependency() {
Package::new("script", "1.0.0").publish();
let script = r#"#!/usr/bin/env cargo
//! ```cargo
//! [dependencies]
//! script = "1.0.0"
//! ```
```cargo
[dependencies]
script = "1.0.0"
```
fn main() {
println!("Hello world!");
Expand Down Expand Up @@ -662,11 +659,10 @@ fn main() {
#[cargo_test]
fn test_path_dep() {
let script = r#"#!/usr/bin/env cargo
//! ```cargo
//! [dependencies]
//! bar.path = "./bar"
//! ```
```cargo
[dependencies]
bar.path = "./bar"
```
fn main() {
println!("Hello world!");
Expand Down

0 comments on commit 46ad13b

Please sign in to comment.