Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
cli: Fix a test failing on macos: rad_checkout
Adam Szkoda committed 3 years ago
commit 93ba7f593cd0443a7ff38dff0f12797806115a8d
parent 488f043226678111449f379741aed730316930ec
4 files changed +60 -17
added radicle-cli/examples/rad-checkout-repo-config-linux.md
@@ -0,0 +1,20 @@
+
```
+
$ cd heartwood
+
```
+

+
View the repository configuration:
+

+
```
+
$ cat .git/config
+
[core]
+
	bare = false
+
	repositoryformatversion = 0
+
	filemode = true
+
	logallrefupdates = true
+
[remote "rad"]
+
	url = rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi
+
	fetch = +refs/heads/*:refs/remotes/rad/*
+
[branch "master"]
+
	remote = rad
+
	merge = refs/heads/master
+
```
added radicle-cli/examples/rad-checkout-repo-config-macos.md
@@ -0,0 +1,22 @@
+
```
+
$ cd heartwood
+
```
+

+
View the repository configuration:
+

+
```
+
$ cat .git/config
+
[core]
+
	bare = false
+
	repositoryformatversion = 0
+
	filemode = true
+
	ignorecase = true
+
	precomposeunicode = true
+
	logallrefupdates = true
+
[remote "rad"]
+
	url = rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi
+
	fetch = +refs/heads/*:refs/remotes/rad/*
+
[branch "master"]
+
	remote = rad
+
	merge = refs/heads/master
+
```
modified radicle-cli/examples/rad-checkout.md
@@ -57,20 +57,3 @@ $ git show-ref
f2de534b5e81d7c6e2dcaf58c3dd91573c0a0354 refs/heads/master
f2de534b5e81d7c6e2dcaf58c3dd91573c0a0354 refs/remotes/rad/master
```
-

-
View the repository configuration:
-

-
```
-
$ cat .git/config
-
[core]
-
	bare = false
-
	repositoryformatversion = 0
-
	filemode = true
-
	logallrefupdates = true
-
[remote "rad"]
-
	url = rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi
-
	fetch = +refs/heads/*:refs/remotes/rad/*
-
[branch "master"]
-
	remote = rad
-
	merge = refs/heads/master
-
```
modified radicle-cli/tests/commands.rs
@@ -122,6 +122,24 @@ fn rad_checkout() {
        [],
    )
    .unwrap();
+

+
    if cfg!(target_os = "linux") {
+
        test(
+
            "examples/rad-checkout-repo-config-linux.md",
+
            copy.path(),
+
            Some(&profile.home),
+
            [],
+
        )
+
        .unwrap();
+
    } else if cfg!(target_os = "macos") {
+
        test(
+
            "examples/rad-checkout-repo-config-macos.md",
+
            copy.path(),
+
            Some(&profile.home),
+
            [],
+
        )
+
        .unwrap();
+
    }
}

#[test]