Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
smalltalk: [ Pharo64-11, Pharo64-12, Pharo64-13, Pharo64-14 ]
smalltalk: [ Pharo64-12, Pharo64-13, Pharo64-14 ]
Comment thread
LabordePierre marked this conversation as resolved.
ston: [ .smalltalkci.default.ston ]
runs-on: ${{ matrix.os }}
name: >
Expand All @@ -30,4 +30,4 @@ jobs:
- name: Run ${{ matrix.ston == '.smalltalkci.default.ston' }} tests
run: smalltalkci -s ${{ matrix.smalltalk }} ${{ matrix.ston }}
shell: bash
timeout-minutes: 30
timeout-minutes: 30
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
[![Pharo 11](https://img.shields.io/badge/Pharo-11-%23aac9ff.svg)](https://pharo.org/download)
[![Pharo 12](https://img.shields.io/badge/Pharo-12-%23aac9ff.svg)](https://pharo.org/download)
[![Pharo 13](https://img.shields.io/badge/Pharo-13-%23aac9ff.svg)](https://pharo.org/download)
[![Pharo 14](https://img.shields.io/badge/Pharo-14-%23aac9ff.svg)](https://pharo.org/download)
Expand Down Expand Up @@ -30,4 +29,4 @@ Metacello new

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
7 changes: 7 additions & 0 deletions src/Toplo-Serialization-Stash/ToSwitchIcon.extension.st
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Extension { #name : #ToSwitchIcon }

{ #category : #'*Toplo-Serialization-Stash' }
ToSwitchIcon >> stashChecked [
<stashAccessors>
^ { ([ :e | 'checked: ' , self checked printString ] -> self) onlySetOnStash }
]
51 changes: 50 additions & 1 deletion src/Toplo-Serialization-Tests/ToSerializerTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -552,6 +552,55 @@ ToSerializerTest >> testToRadioButton4 [
self test: origin on: [ :element | self assert: element isCheckable ]
]

{ #category : #tests }
ToSerializerTest >> testToSwitchButton1 [

| origin |
origin := ToSwitchButton new
labelText: 'hello';
yourself.

self test: origin on: [ :element |
self assert: element labelText asString equals: 'hello']
]

{ #category : #tests }
ToSerializerTest >> testToSwitchButton2 [

| origin |
origin := ToSwitchButton new.

self test: origin on: [ :element |
self assert: element label equals: nil.
self deny: element icon equals: nil ]

]

{ #category : #tests }
ToSerializerTest >> testToSwitchButton3 [

| origin |
origin := ToSwitchButton new
checked:true;
yourself.

self assert: origin icon isChecked.

self test: origin on: [ :element |
self assert: element label equals: nil.
self assert: element icon isChecked ]
]

{ #category : #tests }
ToSerializerTest >> testToSwitchButton4 [

| origin |
origin := ToSwitchButton new.

self test: origin on: [ :element |
self assert: element isCheckable ]
]

{ #category : #tests }
ToSerializerTest >> testToTextFieldPlaceholder [

Expand Down Expand Up @@ -596,7 +645,7 @@ ToSerializerTest >> testToToggleButton1 [
ToSerializerTest >> testToToggleButton2 [

| origin |
origin := ToButton new.
origin := ToToggleButton new.

self test: origin on: [ :element |
self assert: element label equals: nil.
Expand Down
Loading