Skip to content

Commit

Permalink
[FIX] package: fix the windows build test
Browse files Browse the repository at this point in the history
As the windows package provides odoo from sources alongs with
python 3, the test of the build was failing.
The odoo-bin.exe was not found because py2exe is not used anymore.

Windows firewall is now disabled from package.py to prevent it
from blocking local xmlrpc calls.

Also, the docker containers were removed when package tests were
finished, even when no docker was involved in the process (e.g. only
a windows build).

This commit fixes the test part of the windows build process.
  • Loading branch information
d-fence committed Nov 3, 2017
1 parent e66ef45 commit 4035d55
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions setup/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,8 @@ def run(self):
self.rsync('"%s" %s@127.0.0.1:' % (setuppath, self.login))
self.ssh("TEMP=/tmp ./%s /S" % setupfile)
self.ssh('PGPASSWORD=openpgpwd /cygdrive/c/"Program Files"/"Odoo %s"/PostgreSQL/bin/createdb.exe -e -U openpg mycompany' % setupversion)
self.ssh('/cygdrive/c/"Program Files"/"Odoo %s"/server/odoo-bin.exe -d mycompany -i base --stop-after-init' % setupversion)
self.ssh('net start %s' % nt_service_name)
self.ssh('netsh advfirewall set publicprofile state off')
self.ssh('/cygdrive/c/"Program Files"/"Odoo {sv}"/python/python.exe \'c:\\Program Files\\Odoo {sv}\\server\\odoo-bin\' -d mycompany -i base --stop-after-init'.format(sv=setupversion))
_rpc_count_modules(port=18069)

#----------------------------------------------------------
Expand Down Expand Up @@ -524,7 +524,7 @@ def main():
shutil.rmtree(o.build_dir)
logging.info('Build dir %s removed' % o.build_dir)

if not o.no_testing:
if not o.no_testing and not (o.no_debian and o.no_rpm and o.no_tarball):
system("docker rm -f `docker ps -a | awk '{print $1 }'` 2>>/dev/null")
logging.info('Remaining dockers removed')

Expand Down

0 comments on commit 4035d55

Please sign in to comment.