Skip to content

Commit

Permalink
Merge branch 'develop' into release/1.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
infeo committed Aug 14, 2024
2 parents 37fc8b6 + 91f6839 commit ec5f08f
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 1 deletion.
6 changes: 6 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,12 @@
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>${slf4j.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

<build>
Expand Down
1 change: 1 addition & 0 deletions src/main/java/module-info.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,5 @@

opens org.cryptomator.linux.tray to org.cryptomator.integrations.api;
opens org.cryptomator.linux.quickaccess to org.cryptomator.integrations.api;
opens org.cryptomator.linux.autostart to org.cryptomator.integrations.api;
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public FreedesktopAutoStartService() {
LOG.debug("JVM property {} not set, using command path", CMD_PROPERTY);
execValue = ProcessHandle.current().info().command().orElse("");
}
this.hasExecValue = execValue.isBlank();
this.hasExecValue = !execValue.isBlank();
this.content = CONTENT_TEMPLATE.formatted(execValue, this.getClass().getName());
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
package org.cryptomator.linux.autostart;

import org.cryptomator.integrations.autostart.AutoStartProvider;
import org.cryptomator.integrations.common.IntegrationsLoader;
import org.cryptomator.integrations.quickaccess.QuickAccessService;
import org.cryptomator.linux.quickaccess.DolphinPlaces;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.MethodOrderer;
import org.junit.jupiter.api.Order;
import org.junit.jupiter.api.Test;
Expand All @@ -11,6 +17,16 @@ public class FreedesktopAutoStartIT {

FreedesktopAutoStartService inTest = new FreedesktopAutoStartService();

@Test
@DisplayName("If freedesktop dirs are present, isSupported returns true and service is contained in the service provider stream")
@Disabled
public void testSupport() {
Assertions.assertTrue(inTest.isSupported());

var optionalService = IntegrationsLoader.loadAll(AutoStartProvider.class).filter(s -> s.getClass().getName().equals("org.cryptomator.linux.autostart.FreedesktopAutoStartService")).findAny();
Assertions.assertTrue(optionalService.isPresent());
}

@Test
@Order(1)
public void testAutostartEnable() {
Expand Down

0 comments on commit ec5f08f

Please sign in to comment.