Skip to content

Conversation

Schahen
Copy link

@Schahen Schahen commented Feb 27, 2024

Basically this is start for having more and more common tests for keyboard-related staff

@Schahen Schahen requested a review from eymar February 27, 2024 17:26
@Schahen Schahen self-assigned this Feb 27, 2024
Comment on lines 65 to 75
Key.AltLeft -> false
Key.MetaLeft -> false
Key.ShiftLeft -> false
Key.CtrlLeft -> false
Key.Delete -> false
Key.DirectionLeft -> false
Key.DirectionRight -> false
Key.DirectionDown -> false
Key.DirectionUp -> false
Key.Home -> false
Key.MoveEnd -> false
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can probably be a setOf.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make sense, pushed this change.

else -> DefaultKeyboardActions
}

internal class WasmSelectionTests :
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably doesn't need to be internal. But I checked the tests run anyway - wasn't sure.

Copy link
Author

@Schahen Schahen Feb 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eymar
it's internal, because CommonSelectionTests is internal, so we can either:

  • make CommonSelectionTests tests public as well
    or
  • leave the way it is

both is fine with me, the "leave it as it is option" however is - I can not argue - more fragile - I can imagine that something will change in tooling, internal tests will be just ignored and we'll miss it.

@Schahen Schahen requested a review from eymar February 28, 2024 12:38
@Schahen Schahen force-pushed the COMPOSE-823-selection-tests-pr branch from 7b5307e to 38f74b2 Compare February 28, 2024 13:53
@Schahen
Copy link
Author

Schahen commented Feb 28, 2024

In the framework of this PR we've decided to:

  • solve the same propblem abstract fun setPlatformDefaultKeyMapping(value: KeyMapping) currently does but via expect/actual
  • refactor a bit KeyMapping.desktop.kt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants