On Tue, 14 Apr 2020 at 09:26:44, Frédéric Mangano-Tarumi wrote:
> Hi Lukas,
> 
> Lukas Fleischer [2020-04-14 08:54:03 -0400]
> > On Sun, 12 Apr 2020 at 12:55:46, Frédéric Mangano-Tarumi wrote:
> > > +    base_uri = aurweb.config.get("options", "aur_location")
> > > +    proxy = WsgiHttpProxy(base_uri)
> > > +    return werkzeug.test.Client(proxy, Response)
> > 
> > If I understand correctly, this runs tests against our production setup
> > at aur.archlinux.org. Is that what you ultimately plan to do in the
> > transition phase?
> 
> No way! aur_location refers to the development setup address. Its
> default value in our sample configuration is http://localhost:8080,
> which is fine. Note that in my first test I also accessed the database
> directly too, so the environment is not entirely blackboxed.

Could you quickly point me to where that default value is configured?
Both the testing configuration generated by test/setup.sh and the sample
configuration at conf/config.defaults seem to use our production setup.

> > On a related note, the current test suite has been designed to run in an
> > isolated environment without any prior configuration or network
> > connectivity.
> 
> We could spawn PHP and prepare the SQLite database when the test suite
> starts, then clean up everything on exit. If we use Unix sockets
> everywhere, we may be able to avoid using a TCP port too.
> 
> That is only useful during the transition phase, and as long as we don\u2019t
> have Docker. If you believe we should invest time in auto-spawning, I
> can submit a follow-up patch. Beside self-containment, the test suite
> will have full control over its data set, so it actually sounds like a
> good thing to do even in that temporary phase. It shouldn\u2019t be too hard
> anyway. What do you think?

If it's easy to do that without a huge overhead, I am all for it.

We should still try to keep the tests that require these preparatory
steps separate from tests that don't, just in case anybody wants to run
the tests without having to install all the additional components.

Lukas

Reply via email to