Skip to content

Commit 6ef3f8f

Browse files
committed
remove fakedroid
1 parent d7c432b commit 6ef3f8f

File tree

6 files changed

+5
-220
lines changed

6 files changed

+5
-220
lines changed

Diff for: README.md

+4-28
Original file line numberDiff line numberDiff line change
@@ -215,44 +215,20 @@ will expand to `.#nixOnDroidConfigurations.device`). If you run `nix-on-droid sw
215215
Therefore, every evaluation of a flake configuration will be executed with `--impure` flag. (This behaviour will be
216216
dropped as soon as the default setup does not require it anymore.)
217217
218-
## Emulate Nix-on-Droid-like environment with `fakedroid`
219-
220-
For easier debugging and testing, there is a so-called `fakedroid` environment which
221-
emulates the on-device environment including proot as good as possible.
222-
223-
You can enter this emulated environment with
224-
225-
```sh
226-
nix run --impure ".#fakedroid"
227-
```
228-
229-
This will install Nix-on-Droid with initial channel setup and save the state of
230-
this session in the `.fakedroid` directory in the project directory. To enter this
231-
environment with initial flake setup, set `USE_FLAKE=1` as environment variable.
232-
Channel and flake setups can co-exist in the `.fakedroid` state directory. To
233-
rebuild/re-test the bootstrap process, remove the `.fakedroid` directory.
234-
235-
To only run a command in fakedroid and not enter an interactive shell, just call it
236-
with the command as arguments:
237-
238-
```sh
239-
nix run --impure ".#fakedroid" -- ls -l
240-
```
241-
242218
## Testing
243219
244220
In the [./tests/on-device](./tests/on-device) directory, there is small set
245-
of [bats](https://github.com/bats-core/bats-core) tests that can be executed on the
246-
android device or run in the `fakedroid` environment.
221+
of [bats](https://github.com/bats-core/bats-core) tests
222+
that can be executed on a real or emulated android device.
247223
248-
To run the tests (on device or in fakedroid), run
224+
To run the tests, execute
249225
250226
```sh
251227
nix-on-droid on-device-test
252228
```
253229
254230
**Note:** This currently requires a channel setup and should only be executed on
255-
clean installations.
231+
clean, disposable installations.
256232
257233
## Tips
258234

Diff for: flake.nix

-10
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@
6565
type = "app";
6666
program = toString (import ./scripts/deploy.nix { inherit nixpkgs system; });
6767
};
68-
69-
fakedroid = {
70-
type = "app";
71-
program = toString self.packages.${system}.fakedroid;
72-
};
7368
});
7469

7570
checks = forEachSystem (system: {
@@ -126,11 +121,6 @@
126121
};
127122
in
128123
{
129-
fakedroid = import ./tests {
130-
inherit system;
131-
nixpkgs = nixpkgs-for-bootstrap;
132-
};
133-
134124
nix-on-droid = nixpkgs.legacyPackages.${system}.callPackage ./nix-on-droid { };
135125
}
136126
// nixOnDroidPkgs.customPkgs

Diff for: nix-on-droid/nix-on-droid.sh

+1-9
Original file line numberDiff line numberDiff line change
@@ -87,15 +87,7 @@ function doHelp() {
8787
}
8888

8989
function doOnDeviceTest() {
90-
# This is for maintainer convenience only, see tests/on-device/.run.sh
91-
92-
# /n-o-d/unpacked is available in fakedroid environment
93-
if [[ -d "/n-o-d/unpacked" ]]; then
94-
export NIX_PATH="nix-on-droid=/n-o-d/unpacked:$NIX_PATH"
95-
else
96-
nix-channel --update nix-on-droid
97-
fi
98-
90+
nix-channel --update nix-on-droid
9991
exec "$(nix-instantiate --eval --expr \
10092
"<nix-on-droid/tests/on-device/.run.sh>")" "$@"
10193
}

Diff for: pkgs/default.nix

-5
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@ let
6565
bootstrapZip = callPackage ./bootstrap-zip.nix { };
6666
prootTermux = callPackage ./cross-compiling/proot-termux.nix { };
6767
tallocStatic = callPackage ./cross-compiling/talloc-static.nix { };
68-
prootTermuxTest = callPackage ./proot-termux {
69-
inherit (pkgs) stdenv;
70-
static = false;
71-
outputBinaryName = "proot";
72-
};
7368
};
7469
in
7570

Diff for: tests/default.nix

-41
This file was deleted.

Diff for: tests/fakedroid.sh

-127
This file was deleted.

0 commit comments

Comments
 (0)