Skip to content

Commit

Permalink
Fix tests and install.sh for Ubuntu 20 action runner.
Browse files Browse the repository at this point in the history
Undoing some of the changes from d93cba6 now that we've switched the action runner back to Ubuntu 20.
  • Loading branch information
chfritz committed Mar 15, 2024
1 parent 4d51317 commit 196c961
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ if [[ $(uname -s) == 'Linux' ]]; then
g++ \
libgtk-3-dev \
gir1.2-gtk-3.0 \
libsoup-3.0-0 \
gir1.2-soup-3.0 \
libsoup2.4-1 \
gir1.2-soup-2.4 \
libcairo2 \
libcairo2-dev \
libgstreamer1.0-0 \
Expand Down
2 changes: 1 addition & 1 deletion tests/conversion__g_hash.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@


const gi = require('../lib/')
const Soup = gi.require('Soup', '3.0')
const Soup = gi.require('Soup')
const common = require('./__common__.js')

/*
Expand Down
2 changes: 1 addition & 1 deletion tests/conversion__g_s_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*/

const gi = require('../lib/')
const Soup = gi.require('Soup', '3.0')
const Soup = gi.require('Soup')
const common = require('./__common__.js')

const input = 'Content-Type;q=1, Accept;q=0.2, X-Custom;q=0.1, Zero;q=0'
Expand Down
2 changes: 1 addition & 1 deletion tests/function_call__invalid_type.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

const gi = require('../lib/')
const Gtk = gi.require('Gtk', '3.0')
const Soup = gi.require('Soup', '3.0')
const Soup = gi.require('Soup')
const GLib = gi.require('GLib', '2.0')
const common = require('./__common__.js')

Expand Down
10 changes: 5 additions & 5 deletions tests/object__initialization.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
const gi = require('../lib/')
const GLib = gi.require('GLib', '2.0')
const Gtk = gi.require('Gtk', '3.0')
const Soup = gi.require('Soup', '3.0')
const Soup = gi.require('Soup')
const { describe, it, mustThrow, expect, assert } = require('./__common__.js')

Gtk.init()
Expand All @@ -21,20 +21,20 @@ describe('WrapperFromGObject', () => {
describe('new GObject({ ... })', () => {

it('works', () => {
const uri = GLib.uriParse('http://google.com', 0/*GLib.UriFlags.G_URI_FLAGS_NONE*/)
const uri = new Soup.URI('http://google.com', 0/*GLib.UriFlags.G_URI_FLAGS_NONE*/)
const message = new Soup.Message({
method: 'GET',
uri: uri,
})

expect(message.method, 'GET')
assert(message.uri instanceof GLib.Uri, 'message.uri not instanceof GLib.Uri')
assert(message.uri instanceof Soup.URI, 'message.uri not instanceof GLib.Uri')
})

it('fails with wrong property types',
mustThrow(/Cannot convert value.*to type GUri/, () => {
mustThrow(/Cannot convert value.*to type SoupURI/, () => {
const message = new Soup.Message({
uri: 'http://google.com', // invalid type, should be GUri
uri: 'http://google.com', // invalid type, should be Soup.URI
})
}))

Expand Down
2 changes: 1 addition & 1 deletion tests/regressions.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
const gi = require('../lib/')
const Gst = gi.require('Gst', '1.0')
const Gtk = gi.require('Gtk', '3.0');
const Soup = gi.require('Soup', '3.0')
const Soup = gi.require('Soup')
const Cairo = gi.require('cairo', '1.0')
const { describe, expect } = require('./__common__.js')

Expand Down

0 comments on commit 196c961

Please sign in to comment.