mirror of
https://github.com/jely2002/youtube-dl-gui.git
synced 2021-11-01 22:46:21 +03:00
test: update Filepaths.test.js to account for changed functionality
This commit is contained in:
@@ -68,12 +68,13 @@ describe('generate filepaths', () => {
|
||||
await instance.generateFilepaths();
|
||||
expect(instance.createHomeFolder).toBeCalledTimes(1);
|
||||
});
|
||||
it('calls create appdata folder when this version is used', async () => {
|
||||
it('calls create portable folder when this version is used', async () => {
|
||||
const instance = instanceBuilder(true, true);
|
||||
instance.platform = "win32portable";
|
||||
instance.createAppDataFolder = jest.fn().mockResolvedValue(undefined);
|
||||
process.env.PORTABLE_EXECUTABLE_DIR = "test/dir/for/portable/executable";
|
||||
instance.createPortableFolder = jest.fn().mockResolvedValue(undefined);
|
||||
await instance.generateFilepaths();
|
||||
expect(instance.createAppDataFolder).toBeCalledTimes(1);
|
||||
expect(instance.createPortableFolder).toBeCalledTimes(1);
|
||||
})
|
||||
it('sets permissions on darwin and linux', async () => {
|
||||
const platforms = ["win32", "linux", "darwin"];
|
||||
|
||||
Reference in New Issue
Block a user