Skip to content

Tests perhaps shouldn't assume HOME always exists #260

@purcell

Description

@purcell

In versions after 0.6.0, the tests fail while building under Nix, because in that setting $HOME is a placeholder path that doesn't exist. So the assumption here is incorrect:

// parent (~/) always exists

This has prevented auto-updates of lstk in nixpkgs — I've opened a downstream PR to work around this, by giving the tests a fake $HOME temporarily. However, ideally tests shouldn't mutate the host user's actual home dir, or be affected by any pre-existing config found there. I might suggest that tests could set $HOME to a disposable temp dir at start-up.

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions