Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename edgedb binary to gel #1514

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ authors = ["Gel Data Inc. <[email protected]>"]
edition = "2018"

[[bin]]
name = "edgedb"
name = "gel"
path = "src/main.rs"

[features]
Expand Down
6 changes: 3 additions & 3 deletions tests/func/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ pub const BRANDING_CLI_CMD: &str = if cfg!(feature = "gel") {
};

fn edgedb_cli_cmd() -> assert_cmd::Command {
let mut cmd = Command::cargo_bin("edgedb").expect("binary found");
let mut cmd = Command::cargo_bin("gel").expect("binary found");
cmd.timeout(Duration::from_secs(60));
cmd.env("CLICOLOR", "0").arg("--no-cli-update-check");
cmd
Expand Down Expand Up @@ -127,7 +127,7 @@ impl ServerGuard {
use assert_cmd::cargo::CommandCargoExt;
use rexpect::session::spawn_command;

let mut cmd = process::Command::cargo_bin("edgedb").expect("binary found");
let mut cmd = process::Command::cargo_bin("gel").expect("binary found");
cmd.arg("--no-cli-update-check");
cmd.arg("--admin");
cmd.arg("--unix-path").arg(&self.0.info.socket_dir);
Expand All @@ -142,7 +142,7 @@ impl ServerGuard {
use assert_cmd::cargo::CommandCargoExt;
use rexpect::session::spawn_command;

let mut cmd = process::Command::cargo_bin("edgedb").expect("binary found");
let mut cmd = process::Command::cargo_bin("gel").expect("binary found");
cmd.arg("--no-cli-update-check");
cmd.arg("--admin");
cmd.arg("--unix-path").arg(&self.0.info.socket_dir);
Expand Down
2 changes: 1 addition & 1 deletion tests/func/non_interactive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ fn stdin_password() {

#[test]
fn strict_version_check() {
Command::cargo_bin("edgedb")
Command::cargo_bin("gel")
.expect("binary found")
.env("EDGEDB_RUN_VERSION_CHECK", "strict")
.arg("info")
Expand Down
66 changes: 33 additions & 33 deletions tests/portable_project.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,29 +9,29 @@ use util::*;

#[test]
fn project_link_and_init() {
Command::new("edgedb")
Command::new("gel")
.arg("--version")
.assert()
.context("version", "command-line version option")
.success()
.stdout(predicates::str::contains(EXPECTED_VERSION));

Command::new("edgedb")
Command::new("gel")
.arg("server")
.arg("list-versions")
.assert()
.context("list-versions-before", "list with no installed")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("create")
.arg("inst1")
.assert()
.context("create-1", "created `inst1`")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("info")
.arg("--instance-name")
Expand All @@ -41,7 +41,7 @@ fn project_link_and_init() {
.code(1)
.stderr(predicates::str::contains("is not initialized"));

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("init")
.arg("--link")
Expand All @@ -52,7 +52,7 @@ fn project_link_and_init() {
.context("project-link", "linked `inst1` to project project1")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("info")
.arg("--instance-name")
Expand All @@ -62,15 +62,15 @@ fn project_link_and_init() {
.success()
.stdout(predicates::ord::eq("inst1\n"));

Command::new("edgedb")
Command::new("gel")
.arg("query")
.arg("SELECT 1")
.current_dir("tests/proj/project1")
.assert()
.context("query-1", "query of project")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("init")
.arg("--non-interactive")
Expand All @@ -79,7 +79,7 @@ fn project_link_and_init() {
.context("project-init", "init project2")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("info")
.arg("--instance-name")
Expand All @@ -89,15 +89,15 @@ fn project_link_and_init() {
.success()
.stdout(predicates::ord::eq("project2\n"));

Command::new("edgedb")
Command::new("gel")
.arg("query")
.arg("SELECT 1")
.current_dir("tests/proj/project2")
.assert()
.context("query-2", "query of project2")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("upgrade")
.arg("--force")
Expand All @@ -106,15 +106,15 @@ fn project_link_and_init() {
.context("project-upgrade", "upgrade project")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("query")
.arg("SELECT 1")
.current_dir("tests/proj/project2")
.assert()
.context("query-3", "query after upgrade")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("destroy")
.arg("--instance=project2")
Expand All @@ -123,7 +123,7 @@ fn project_link_and_init() {
.context("destroy-2-no", "should warn")
.code(2);

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("destroy")
.arg("--instance=inst1")
Expand All @@ -132,7 +132,7 @@ fn project_link_and_init() {
.context("destroy-1-no", "should warn")
.code(2);

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("destroy")
.arg("--instance=project1")
Expand All @@ -144,7 +144,7 @@ fn project_link_and_init() {
)
.code(8); // instance not found

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("list")
.assert()
Expand All @@ -153,7 +153,7 @@ fn project_link_and_init() {
.stdout(predicates::str::contains("inst1"))
.stdout(predicates::str::contains("project2"));

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("destroy")
.arg("--instance=project2")
Expand All @@ -162,7 +162,7 @@ fn project_link_and_init() {
.context("destroy-2", "should destroy")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("list")
.assert()
Expand All @@ -171,7 +171,7 @@ fn project_link_and_init() {
.stdout(predicates::str::contains("inst1"))
.stdout(predicates::str::contains("project2").not());

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("unlink")
.arg("-D")
Expand All @@ -181,7 +181,7 @@ fn project_link_and_init() {
.context("destroy-1", "should unlink and destroy project")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("list")
.assert()
Expand All @@ -190,7 +190,7 @@ fn project_link_and_init() {
.stdout(predicates::str::contains("inst1").not())
.stdout(predicates::str::contains("project2").not());

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("init")
.arg("--non-interactive")
Expand All @@ -199,7 +199,7 @@ fn project_link_and_init() {
.context("project-init-2", "init project2")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("upgrade")
.arg("--to-latest")
Expand All @@ -209,7 +209,7 @@ fn project_link_and_init() {
.context("project-upgrade-2", "upgrade project2")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("status")
.arg("--instance=project2")
Expand All @@ -218,7 +218,7 @@ fn project_link_and_init() {
.context("instance-status", "show extended status")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("revert")
.arg("--instance=project2")
Expand All @@ -227,7 +227,7 @@ fn project_link_and_init() {
.context("project-revert-2", "revert project2")
.success();

Command::new("edgedb")
Command::new("gel")
.arg("project")
.arg("unlink")
.arg("-D")
Expand All @@ -246,14 +246,14 @@ fn hooks() {
let branch_log_file = path::Path::new("tests/proj/project3/branch.log");
fs::remove_file(branch_log_file).ok();

Command::new("edgedb")
Command::new("gel")
.arg("--version")
.assert()
.context("version", "command-line version option")
.success()
.stdout(predicates::str::contains(EXPECTED_VERSION));

Command::new("edgedb")
Command::new("gel")
.arg("instance")
.arg("create")
.arg("inst2")
Expand All @@ -263,7 +263,7 @@ fn hooks() {
.context("instance-create", "")
.success();

Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("project")
.arg("init")
Expand All @@ -283,7 +283,7 @@ fn hooks() {
],
});

Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("branch")
.arg("switch")
Expand All @@ -305,7 +305,7 @@ fn hooks() {
let branch_log = fs::read_to_string(branch_log_file).unwrap();
assert_eq!(branch_log, "another\n");

Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("branch")
.arg("merge")
Expand All @@ -322,7 +322,7 @@ fn hooks() {
],
});

Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("branch")
.arg("wipe")
Expand All @@ -340,7 +340,7 @@ fn hooks() {
],
});

Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("branch")
.arg("switch")
Expand All @@ -363,7 +363,7 @@ fn hooks() {
// branch switch, but with explict --instance arg
// This should prevent hooks from being executed, since
// this action is not executed "on a project", but "on an instance".
Command::new("edgedb")
Command::new("gel")
.current_dir("tests/proj/project3")
.arg("--instance=inst2")
.arg("branch")
Expand Down
Loading
Loading