nixpkgs/nixos/tests/odoo.nix
Karolin Schlegel 4eee509d25 odoo15: init at 15.0-20230720
This contribution adds `odoo15` as a fixed version. To allow reusing the
existing test for Odoo, I made the package attribute configurable. To
reference the test for `odoo15` in `passthru` I added it to
`all-tests.nix`.
2023-08-27 09:52:43 +02:00

27 lines
709 B
Nix

import ./make-test-python.nix ({ pkgs, lib, package ? pkgs.odoo, ...} : {
name = "odoo";
meta.maintainers = with lib.maintainers; [ mkg20001 ];
nodes = {
server = { ... }: {
services.nginx = {
enable = true;
recommendedProxySettings = true;
};
services.odoo = {
enable = true;
package = package;
domain = "localhost";
};
};
};
testScript = { nodes, ... }:
''
server.wait_for_unit("odoo.service")
server.wait_until_succeeds("curl -s http://localhost:8069/web/database/selector | grep '<title>Odoo</title>'")
server.succeed("curl -s http://localhost/web/database/selector | grep '<title>Odoo</title>'")
'';
})