Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion enterprise
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import androidx.compose.runtime.remember
import androidx.compose.runtime.rememberCoroutineScope
import androidx.compose.runtime.setValue
import androidx.compose.runtime.snapshots.SnapshotStateList
import androidx.compose.ui.graphics.toArgb
import dev.zacsweers.metro.Inject
import io.element.android.features.enterprise.api.EnterpriseService
import io.element.android.features.preferences.impl.developer.tracing.toLogLevel
Expand Down Expand Up @@ -139,7 +140,11 @@ class DeveloperSettingsPresenter(
}
is DeveloperSettingsEvents.ChangeBrandColor -> coroutineScope.launch {
showColorPicker = false
val color = event.color?.value?.toHexString(HexFormat.UpperCase)?.substring(2, 8)
val color = event.color
?.toArgb()
?.toHexString(HexFormat.UpperCase)
?.substring(2, 8)
?.padStart(7, '#')
enterpriseService.overrideBrandColor(sessionId, color)
}
is DeveloperSettingsEvents.SetShowColorPicker -> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ class DeveloperSettingsPresenterTest {
assertThat(awaitItem().showColorPicker).isFalse()
skipItems(1)
overrideBrandColorResult.assertions().isCalledOnce()
.with(value(A_SESSION_ID), value("00FF00"))
.with(value(A_SESSION_ID), value("#00FF00"))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import com.lemonappdev.konsist.api.verify.assertTrue
import dev.zacsweers.metro.Assisted
import dev.zacsweers.metro.ContributesBinding
import dev.zacsweers.metro.Inject
import org.junit.Ignore
import org.junit.Test

class KonsistDiTest {
Expand All @@ -36,7 +35,6 @@ class KonsistDiTest {
}
}

@Ignore("Disabled to give time to branch and private module to remove the annotation")
@Test
fun `class annotated with @ContributesBinding does not need to be annotated with @Inject anymore`() {
Konsist
Expand Down
Loading