[Bug 32074] should run regression tests against a mock Avahi by default
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Wed Apr 6 14:13:38 CEST 2011
https://bugs.freedesktop.org/show_bug.cgi?id=32074
Jonny Lamb <jonny.lamb at collabora.co.uk> changed:
What |Removed |Added
----------------------------------------------------------------------------
URL|http://git.collabora.co.uk/ |http://cgit.freedesktop.org
|?p=user/tomeu/telepathy-sal |/~jonny/telepathy-salut/log
|ut.git;a=shortlog;h=refs/he |?h=mock-avahi
|ads/mock-avahi-4 |
Status Whiteboard|review- |
AssignedTo|simon.mcvittie at collabora.co |jonny.lamb at collabora.co.uk
|.uk |
--- Comment #2 from Jonny Lamb <jonny.lamb at collabora.co.uk> 2011-04-06 05:13:38 PDT ---
I've taken this branch over.
(In reply to comment #1)
> - e = self.q.expect('service-resolved', service = service)
> + e = self.q.expect('service-resolved', service = service,
> + protocol = avahi.PROTO_INET6)
>
> Check that this works for the real network
Done.
> try:
> self.request_ft_channel()
> except dbus.DBusException, e:
> - assert e.get_dbus_name() == cs.NOT_AVAILABLE
> + if e.get_dbus_name() != cs.NOT_AVAILABLE:
> + raise
>
> Good independently, but call_async + expect would be even better
This is actually a bit of a pain because request_ft_channel does more than just
call CreateChannel synchronously. I'm going to leave this for now.
> +def get_domain():
> + full_domain = socket.getfqdn()
> + if '.' in full_domain:
> + return full_domain.split('.', 1)[1]
> + else:
> + return ''
>
> Shouldn't use this, laptops' FQDNs are meaningless. All we need is
> Avahi's idea of the hostname (which we control anyway, so set it to
> mockavahi) and Avahi's advertising domain (.local).
Done.
> + emit_signal(service_resolver.object_path,
> + AVAHI_IFACE_SERVICE_RESOLVER, 'Failure',
> + service_resolver.client, 's',
> + 'fill with a proper error string')
>
> Indeed.
Done.
> + @dbus.service.method(dbus_interface=AVAHI_IFACE_SERVER,
> + in_signature='', out_signature='s')
> + def GetHostName(self):
> + return socket.gethostname()
>
> Hard-code this?
Done.
> + @dbus.service.method(dbus_interface=AVAHI_IFACE_SERVER,
> + in_signature='', out_signature='s')
> + def GetHostNameFqdn(self):
> + return socket.getfqdn()
>
> Hard-code this?
Done.
> + @dbus.service.method(dbus_interface=AVAHI_IFACE_SERVER,
> + in_signature='', out_signature='s')
> + def GetDomainName(self):
> + return get_domain()
>
> And this?
Done.
> + @dbus.service.method(dbus_interface=AVAHI_IFACE_SERVER,
> + in_signature='', out_signature='i')
> + def GetState(self):
> + return 2
>
> Magic number
Fixed.
> + @dbus.service.method(dbus_interface=AVAHI_IFACE_ENTRY_GROUP,
> + in_signature='', out_signature='')
> + def Commit(self):
> + self._set_state(1)
> + glib.idle_add(lambda: self._set_state(2))
>
> Magic numbers
Fixed.
> +[D-BUS Service]
> +Name=org.freedesktop.Avahi
> +Exec=dumb
>
> Should use the fake-launch helper from MC, or not be activatable at all
Deleted service file. We're not testing service activation here.
--
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
More information about the telepathy-bugs
mailing list