[libcalamares] Fix targetPath() tests

- there is less simplification done than you might think
This commit is contained in:
Adriaan de Groot 2020-02-07 13:53:49 +01:00
parent daa5b804b3
commit 8d23e665ea

View File

@ -78,8 +78,8 @@ TestPaths::testTargetPath()
{
// Paths mapped normally
QCOMPARE( m_system->targetPath( "/etc/calamares" ), QStringLiteral( "/tmp/etc/calamares" ) );
QCOMPARE( m_system->targetPath( "//etc//calamares" ), QStringLiteral( "/tmp/etc/calamares" ) ); // extra /
QCOMPARE( m_system->targetPath( "etc/calamares" ), QString() ); // NOT ABSOLUTE
QCOMPARE( m_system->targetPath( "//etc//calamares" ), QStringLiteral( "/tmp//etc//calamares" ) ); // extra / are not cleaned up
QCOMPARE( m_system->targetPath( "etc/calamares" ), QStringLiteral( "/tmp/etc/calamares" ) ); // relative to root
}
QTEST_GUILESS_MAIN( TestPaths )