Skip to content

Commit db29b48

Browse files
authored
Add Ruby 4, truffle ruby and jruby to build (#167)
* Add Ruby 4, truffle ruby and jruby to build * Updated tests to work on jruby There was only one issue with the test suite, that on jruby TCPServer.new cannot be given a nil port, it must be an integer. However passing 0 should have the same effect on both cruby and jruby.
1 parent f99f2c9 commit db29b48

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎.github/workflows/build.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ jobs:
66
fail-fast: false
77
matrix:
88
os: [ubuntu-latest]
9-
ruby: ['2.3', '2.4', '2.5', '2.6', '2.7', '3.0', '3.1', '3.2', '3.3', '3.4', '3.5']
9+
ruby: ['2.3', '2.4', '2.5', '2.6', '2.7', '3.0', '3.1', '3.2', '3.3', '3.4', '4.0', 'jruby-10.1.0', 'truffleruby-33']
1010
runs-on: ${{ matrix.os }}
1111
steps:
1212
- uses: actions/checkout@v3

‎spec/fake_server.rb‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class MQTT::FakeServer
3434
#
3535
# If no port is given, bind to a random port number
3636
# If no bind address is given, bind to localhost
37-
def initialize(port=nil, bind_address='127.0.0.1')
37+
def initialize(port=0, bind_address='127.0.0.1')
3838
@port = port
3939
@address = bind_address
4040
@pings_received = 0

0 commit comments

Comments
 (0)