Skip to content

Commit

Permalink
fix: main compilation (#319)
Browse files Browse the repository at this point in the history
  • Loading branch information
callicles authored Feb 2, 2024
1 parent cc2d515 commit ea168d0
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 11 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/test-framework-cli.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ jobs:
command: check
args: --manifest-path ./apps/framework-cli/Cargo.toml

- name: Run cargo Build in release mode
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./apps/framework-cli/Cargo.toml --release --locked

test-macos:
name: Test Suite (MacOS)
env:
Expand Down
1 change: 1 addition & 0 deletions apps/framework-cli/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion apps/framework-cli/src/project.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ impl Project {
std::fs::write(&self.project_file_location, project)?;
Ok(())
}
Err(err) => Err(std::io::Error::new(
Err(_err) => Err(std::io::Error::new(
std::io::ErrorKind::Other,
"Failed to serialize project",
)),
Expand Down
6 changes: 3 additions & 3 deletions apps/framework-cli/tests/cli_dev.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ fn setup_dev() -> Result<CargoDev, anyhow::Error> {
let dir = temp.path().to_str().unwrap();

// Setup the project with the cli
let mut init_cmd = Command::cargo_bin("igloo-cli")?;
let mut init_cmd = Command::cargo_bin("moose-cli")?;

init_cmd
.env("IGLOO-FEATURES-COMING_SOON_WALL", "false")
Expand All @@ -35,7 +35,7 @@ fn setup_dev() -> Result<CargoDev, anyhow::Error> {

init_cmd.assert().success();

let mut cmd = Command::cargo_bin("igloo-cli")?;
let mut cmd = Command::cargo_bin("moose-cli")?;

let dev_process = cmd
.env("IGLOO-FEATURES-COMING_SOON_WALL", "false")
Expand Down Expand Up @@ -71,7 +71,7 @@ fn teardown_dev(mut dev_state: CargoDev) {
fn should_not_run_if_coming_soon_wall_is_blocking() -> Result<(), anyhow::Error> {
let temp = assert_fs::TempDir::new().unwrap();

let mut cmd = Command::cargo_bin("igloo-cli")?;
let mut cmd = Command::cargo_bin("moose-cli")?;

cmd.env("IGLOO-FEATURES-COMING_SOON_WALL", "true")
.arg("dev")
Expand Down
14 changes: 7 additions & 7 deletions apps/framework-cli/tests/cli_init.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use std::process::Command;

#[test]
fn cannot_run_cli_init_without_args() -> Result<(), Box<dyn std::error::Error>> {
let mut cmd = Command::cargo_bin("igloo-cli")?;
let mut cmd = Command::cargo_bin("moose-cli")?;

cmd.arg("init");
cmd.assert().failure().stderr(predicate::str::contains(
Expand All @@ -21,9 +21,9 @@ fn can_run_cli_init() -> Result<(), Box<dyn std::error::Error>> {
let dir: &str = temp.path().to_str().unwrap();

// List the content of dir
temp.child(".igloo").assert(predicate::path::missing());
temp.child(".moose").assert(predicate::path::missing());

let mut cmd = Command::cargo_bin("igloo-cli")?;
let mut cmd = Command::cargo_bin("moose-cli")?;

cmd.env("IGLOO-FEATURES-COMING_SOON_WALL", "false")
.arg("init")
Expand All @@ -35,7 +35,7 @@ fn can_run_cli_init() -> Result<(), Box<dyn std::error::Error>> {

// TODO add more specific tests when the layout of the
// app is more stable
temp.child(".igloo").assert(predicate::path::exists());
temp.child(".moose").assert(predicate::path::exists());
temp.child("package.json").assert(predicate::path::exists());
temp.child("app").assert(predicate::path::exists());

Expand All @@ -48,9 +48,9 @@ fn should_not_run_if_coming_soon_wall_is_blocking() -> Result<(), Box<dyn std::e
let dir: &str = temp.path().to_str().unwrap();

// List the content of dir
temp.child(".igloo").assert(predicate::path::missing());
temp.child(".moose").assert(predicate::path::missing());

let mut cmd = Command::cargo_bin("igloo-cli")?;
let mut cmd = Command::cargo_bin("moose-cli")?;

cmd.env("IGLOO-FEATURES-COMING_SOON_WALL", "true")
.arg("init")
Expand All @@ -60,7 +60,7 @@ fn should_not_run_if_coming_soon_wall_is_blocking() -> Result<(), Box<dyn std::e

cmd.assert().success();

temp.child(".igloo").assert(predicate::path::missing());
temp.child(".moose").assert(predicate::path::missing());
temp.child("package.json")
.assert(predicate::path::missing());
temp.child("app").assert(predicate::path::missing());
Expand Down

0 comments on commit ea168d0

Please sign in to comment.