1
0
Fork 0
mirror of https://github.com/romkatv/powerlevel10k.git synced 2024-11-11 00:00:06 +00:00

Fix tests

This commit is contained in:
Dominik Ritter 2018-08-04 22:57:06 +02:00
parent 81fd69ae98
commit e7cbcc5187
2 changed files with 6 additions and 0 deletions

View file

@ -158,6 +158,10 @@ function testBatterySegmentIfBatteryIsNormalWithAcpiEnabledOnLinux() {
assertEquals "%K{black} %F{white%}🔋 %f%F{white}50%% (1:38) " "$(prompt_battery left 1 false ${FOLDER})"
unalias date &>/dev/null
# unaliasing date fails where it was never aliased (e.g. on Linux).
# This causes the whole test to fail, because the return code is
# non-zero.
return 0
}
function testBatterySegmentIfBatteryIsCalculatingWithAcpiEnabledOnLinux() {

View file

@ -16,6 +16,8 @@ function setUp() {
function tearDown() {
# Restore old variables
[[ -n "$OLD_DEFAULT_USER" ]] && DEFAULT_USER=$OLD_DEFAULT_USER
return 0
}
function testContextSegmentDoesNotGetRenderedWithDefaultUser() {