summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Repository.mk6
-rw-r--r--instsetoo_native/CustomTarget_install.mk3
-rw-r--r--instsetoo_native/util/openoffice.lst.in85
-rw-r--r--instsetoo_native/util/pack.lst1
-rw-r--r--scp2/InstallModule_smoketest.mk16
-rw-r--r--scp2/InstallScript_test.mk16
-rw-r--r--scp2/Module_scp2.mk2
-rw-r--r--scp2/source/smoketest/smoketest.scp171
-rw-r--r--setup_native/Package_packinfo.mk1
-rw-r--r--setup_native/source/packinfo/packinfo_test.txt35
-rw-r--r--smoketest/Module_smoketest.mk2
-rw-r--r--smoketest/Package_losmoketest.mk15
-rw-r--r--smoketest/Package_smoketestdoc.mk14
-rwxr-xr-xsmoketest/lodownloadtest.py662
-rwxr-xr-xsmoketest/losmoketest41
-rw-r--r--smoketest/losmoketest.readme186
16 files changed, 1 insertions, 1255 deletions
diff --git a/Repository.mk b/Repository.mk
index 6a4f6bac1be0..cb876cb64c5a 100644
--- a/Repository.mk
+++ b/Repository.mk
@@ -24,6 +24,7 @@ $(eval $(call gb_Helper_register_executables,NONE, \
cfgex \
concat-deps \
cpp \
+ cppunittester \
$(if $(filter MSC,$(COM)), \
gcc-wrapper \
g++-wrapper \
@@ -445,11 +446,6 @@ $(eval $(call gb_Helper_register_libraries,PLAINLIBS_OOO, \
unotest \
))
-# this is packaged in the "Test" instset, in the "program" dir :-/
-$(eval $(call gb_Helper_register_executables,OOO, \
- cppunittester \
-))
-
$(eval $(call gb_Helper_register_libraries,PLAINLIBS_NONE, \
subsequenttest \
testtools_cppobj \
diff --git a/instsetoo_native/CustomTarget_install.mk b/instsetoo_native/CustomTarget_install.mk
index 04e78d4eecc3..9082cc561b62 100644
--- a/instsetoo_native/CustomTarget_install.mk
+++ b/instsetoo_native/CustomTarget_install.mk
@@ -114,9 +114,6 @@ else # LIBO_TEST_INSTALL
ifeq (ODK,$(filter ODK,$(BUILD_TYPE)))
$(call instsetoo_native_install_command,sdkoo,en-US,_SDK,,$(PKGFORMAT))
endif
-ifeq (,$(filter WNT MACOSX,$(OS)))
- $(call instsetoo_native_install_command,not-used,en-US,_Test,,$(PKGFORMAT))
-endif
ifeq (HELP,$(filter HELP,$(BUILD_TYPE))$(filter MACOSX,$(OS)))
$(foreach lang,$(gb_HELP_LANGS),\
$(call instsetoo_native_install_command,ooohelppack,$(lang),,-helppack,$(PKGFORMAT)))
diff --git a/instsetoo_native/util/openoffice.lst.in b/instsetoo_native/util/openoffice.lst.in
index 0bc155525808..a23b6a113bcc 100644
--- a/instsetoo_native/util/openoffice.lst.in
+++ b/instsetoo_native/util/openoffice.lst.in
@@ -219,88 +219,3 @@ LibreOffice_Dev_SDK
include {solarpath}/bin.{minor}/osl,{solarpath}/bin.{minor},{solarpath}/lib.{minor},{solarpath}/pck.{minor},{filelistpath}/PackageSet,{filelistpath}/GeneratedPackage,{filelistpath}/Package,{instdir},{instdir}/ure/lib
}
}
-
-LibreOffice_Test
-{
- Settings
- {
- downloadname LibreOffice-Test_{packageversion}_{os}_install_{languages}
- variables
- {
- PRODUCTNAME LibreOffice
- PRODUCTVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@
- PRODUCTEXTENSION .@LIBO_VERSION_MICRO@.@LIBO_VERSION_PATCH@@LIBO_VERSION_SUFFIX@
- POSTVERSIONEXTENSION TEST
- BUNDLEIDENTIFIER @MACOSX_BUNDLE_IDENTIFIER@.Test
- BRANDPACKAGEVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@
- PACKAGEVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@.@LIBO_VERSION_MICRO@.@LIBO_VERSION_PATCH@@LIBO_VERSION_SUFFIX@
- PACKAGEREVISION {buildid}
- PACK_INSTALLED 1
- DMG_VOLUMEEXTENSION TEST
- DATABASENAME libreoffice40test
- NO_README_IN_ROOTDIR 1
- LICENSENAME LGPL
- IGNOREDIRECTORYLAYER 1
- NOVERSIONINDIRNAME 0
- NOSPACEINDIRECTORYNAME 1
- NOSHORTDIRECTORYNAMES 1
- CHANGETARGETDIR 1
- DONTUSESTARTMENUFOLDER 1
- STARTCENTER_ADDFEATURE_URL http://extensions.libreoffice.org/
- STARTCENTER_INFO_URL http://www.libreoffice.org/
- STARTCENTER_TEMPLREP_URL http://templates.libreoffice.org/
- DICT_REPO_URL http://extensions.libreoffice.org/dictionaries/
- STARTCENTER_HIDE_EXTERNAL_LINKS 0
- }
- active 1
- compression 5
- script test
- include {solarpath}/bin.{minor}/cppunit,{solarpath}/bin.{minor}/osl,{solarpath}/bin.{minor},{solarpath}/lib.{minor},{instdir}/ure/lib
- }
-}
-
-LibreOffice_Dev_Test
-{
- Settings
- {
- downloadname LibreOfficeDev-Test_{packageversion}_{os}_install_{languages}
- variables
- {
- PRODUCTNAME LibreOfficeDev
- PRODUCTVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@
- PRODUCTEXTENSION .@LIBO_VERSION_MICRO@.@LIBO_VERSION_PATCH@@LIBO_VERSION_SUFFIX@
- WINDOWSBASISROOTNAME LibreOfficeDev @LIBO_VERSION_MAJOR@
- UNIXBASISROOTNAME libreofficedev@LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@
- POSTVERSIONEXTENSION TEST
- BUNDLEIDENTIFIER @MACOSX_BUNDLE_IDENTIFIER@.Test
- BRANDPACKAGEVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@
- PACKAGEVERSION @LIBO_VERSION_MAJOR@.@LIBO_VERSION_MINOR@.@LIBO_VERSION_MICRO@.@LIBO_VERSION_PATCH@@LIBO_VERSION_SUFFIX@
- PACKAGEREVISION {buildid}
- BASISPACKAGEPREFIX lodevbasis
- UREPACKAGEPREFIX libreofficedev
- SOLSUREPACKAGEPREFIX libreofficedev
- REGISTRYLAYERNAME LayerDev
- DEVELOPMENTPRODUCT 1
- PACK_INSTALLED 1
- DMG_VOLUMEEXTENSION TEST
- DATABASENAME libreoffice40devtest
- NO_README_IN_ROOTDIR 1
- LICENSENAME LGPL
- IGNOREDIRECTORYLAYER 1
- NOVERSIONINDIRNAME 0
- NOSPACEINDIRECTORYNAME 1
- NOSHORTDIRECTORYNAMES 1
- CHANGETARGETDIR 1
- DONTUSESTARTMENUFOLDER 1
- STARTCENTER_ADDFEATURE_URL http://extensions.libreoffice.org/
- STARTCENTER_INFO_URL http://www.libreoffice.org/
- STARTCENTER_TEMPLREP_URL http://templates.libreoffice.org/
- DICT_REPO_URL http://extensions.libreoffice.org/dictionaries/
- STARTCENTER_HIDE_EXTERNAL_LINKS 0
- }
- active 1
- compression 5
- script test
- include {solarpath}/bin.{minor}/cppunit,{solarpath}/bin.{minor}/osl,{solarpath}/bin.{minor},{solarpath}/lib.{minor},{instdir}/ure/lib
- }
-}
diff --git a/instsetoo_native/util/pack.lst b/instsetoo_native/util/pack.lst
index 7f6c914f5271..762721d838cd 100644
--- a/instsetoo_native/util/pack.lst
+++ b/instsetoo_native/util/pack.lst
@@ -12,7 +12,6 @@ LibreOffice unxlngi6.pro,unxmacxi.pro,unxsoli4.pro,unxsols4.pro,wntm
#LibreOffice_Dev unxlngi6.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxmacxi.pro,unxlngx6.pro en-US openofficedev
LibreOffice_SDK unxlngi6.pro,unxmacxi.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxlngx6.pro en-US sdkoo
#LibreOffice_Dev_SDK unxlngi6.pro,unxmacxi.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxlngx6.pro en-US sdkoodev
-LibreOffice_Test unxlngi6.pro,unxmacxi.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxlngx6.pro en-US test
LibreOfficeLanguagepack unxlngi6.pro,unxmacxi.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxlngx6.pro en-US|ar|as|ast|be|bg|bn|ca|ca-valencia|cs|da|de|dz|el|en-GB|eo|es|et|eu|fi|fr|ga|gl|gu|he|hi|hu|id|is|it|ja|ka|km|kn|ko|ku|lt|lv|mk|ml|mr|my|nb|nl|nn|oc|om|or|pa-IN|pl|pt|pt-BR|ro|ru|si|sk|sl|sr|sr-Latn|sv|ta|te|th|tr|ug|uk|uz|vi|zh-CN|zh-TW ooolanguagepack
#LibreOfficeLanguagepack unxlngi6,unxsoli4,unxsols4,wntmsci12,unxmacxi de ooolanguagepack
#LibreOfficeDevLanguagepack unxlngi6.pro,unxsoli4.pro,unxsols4.pro,wntmsci12.pro,unxlngx6.pro,unxmacxi.pro ar|as|ast|bg|bn|ca|ca-valencia|cs|da|de|dz|el|en-GB|es|et|eu|fi|fr|ga|gl|gu|he|hi|hu|id|is|it|ja|km|kn|ko|lt|lv|mk|ml|mr|my|nb|nl|nn|oc|om|or|pa-IN|pl|pt|pt-BR|ru|si|sk|sl|sr|sr-Latn|sv|ta|te|th|tr|ug|uk|vi|zh-CN|zh-TW ooodevlanguagepack
diff --git a/scp2/InstallModule_smoketest.mk b/scp2/InstallModule_smoketest.mk
deleted file mode 100644
index f3abe7339123..000000000000
--- a/scp2/InstallModule_smoketest.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-$(eval $(call gb_InstallModule_InstallModule,scp2/smoketest))
-
-$(eval $(call gb_InstallModule_add_scpfiles,scp2/smoketest,\
- scp2/source/smoketest/smoketest \
-))
-
-# vim: set shiftwidth=4 tabstop=4 noexpandtab:
diff --git a/scp2/InstallScript_test.mk b/scp2/InstallScript_test.mk
deleted file mode 100644
index 18325c2439fc..000000000000
--- a/scp2/InstallScript_test.mk
+++ /dev/null
@@ -1,16 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-$(eval $(call gb_InstallScript_InstallScript,test))
-
-$(eval $(call gb_InstallScript_use_modules,test,\
- scp2/smoketest \
-))
-
-# vim: set shiftwidth=4 tabstop=4 noexpandtab:
diff --git a/scp2/Module_scp2.mk b/scp2/Module_scp2.mk
index 05911c51faa6..41711fc7fa53 100644
--- a/scp2/Module_scp2.mk
+++ b/scp2/Module_scp2.mk
@@ -26,12 +26,10 @@ $(eval $(call gb_Module_add_targets,scp2,\
InstallModule_onlineupdate \
InstallModule_ooo \
InstallModule_python \
- InstallModule_smoketest \
InstallModule_ure \
InstallModule_writer \
InstallModule_xsltfilter \
InstallScript_setup_osl \
- InstallScript_test \
$(if $(filter ODK,$(BUILD_TYPE)), \
InstallModule_sdkoo \
InstallScript_sdkoo \
diff --git a/scp2/source/smoketest/smoketest.scp b/scp2/source/smoketest/smoketest.scp
deleted file mode 100644
index 9b932081e136..000000000000
--- a/scp2/source/smoketest/smoketest.scp
+++ /dev/null
@@ -1,171 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- */
-
-#include "macros.inc"
-
-Installation gid_Installation_Test
- ProductName = "${PRODUCTNAME}";
- ProductVersion = "${PRODUCTVERSION}";
- ProductExtension = "${PRODUCTEXTENSION}";
-#if defined WNT
- DefaultDestPath = "<winprogpath>\%PRODUCTNAME";
-#else
- DefaultDestPath = "/opt/%PRODUCTNAME";
-#endif
-End
-
-Module gid_Module_Root_Smoketest
- Name = "smoketest";
- Description = "smoketest";
- PackageInfo = "packinfo_test.txt";
-End
-
-#ifndef MACOSX
-Directory gid_Test_Dir_Brand_Root
- ParentID = PREDEFINED_PROGDIR;
- #ifdef WNT
- HostName = "${PRODUCTNAME} ${BRANDPACKAGEVERSION}";
- #else
- HostName = ".";
- #endif
- Styles = (OFFICEDIRECTORY,ISINSTALLLOCATION,CREATE);
-End
-#endif
-
-#if MACOSX
-Directory gid_Test_Dir_Bundle
- ParentID = PD_PROGDIR;
- HostName = "%PRODUCTNAME.app";
- LangPackHostName = "%PRODUCTNAME Language Pack.app";
-End
-
-Directory gid_Test_Dir_Bundle_Contents
- ParentID = gid_Test_Dir_Bundle;
- HostName = "Contents";
- Styles = (OFFICEDIRECTORY);
-End
-#endif
-
-Directory gid_Test_Brand_Dir_Program
-#if defined MACOSX
- ParentID = gid_Test_Dir_Bundle_Contents;
- DosName = "MacOS";
-#else
- ParentID = gid_Test_Dir_Brand_Root;
- DosName = "program";
-#endif
-End
-
-Directory gid_Test_Brand_Dir_Share
-#if defined MACOSX
- ParentID = gid_Test_Dir_Bundle_Contents;
-#else
- ParentID = gid_Test_Dir_Brand_Root;
-#endif
- DosName = "share";
-End
-
-Directory gid_Test_Brand_Dir_Share_Test
- ParentID = gid_Test_Brand_Dir_Share;
- DosName = "test";
-End
-
-
-File gid_Test_File_Txt_License
- TXT_FILE_BODY;
- Dir = gid_Test_Brand_Dir_Share_Test;
- #ifdef UNX
- Name = "LICENSE";
- #endif
- #ifdef WNT
- Name = "license.txt";
- #endif
- Styles = (PACKED, SCPZIP_REPLACE);
-End
-
-File gid_Test_File_Txt_Readme
- TXT_FILE_BODY;
- Dir = gid_Test_Brand_Dir_Share_Test;
- #ifdef UNX
- Name = "README_en-US";
- #endif
- #ifdef WNT
- Name = "readme_en-US.txt";
- #endif
- Styles = (PACKED, SCPZIP_REPLACE);
-End
-
-File gid_Test_File_Misc_Smoketestdoc
- TXT_FILE_BODY;
- Dir = gid_Test_Brand_Dir_Share_Test;
- Name = "smoketestdoc.sxw";
- Styles = (PACKED, SCPZIP_REPLACE);
-End
-
-File gid_Test_File_Bin_LOSmoketest
- BIN_FILE_BODY;
- Dir = gid_Test_Brand_Dir_Program;
- Name = "losmoketest";
- Styles = (PACKED);
-End
-
-File gid_Test_File_Exe_Cppunittester
- BIN_FILE_BODY;
- Dir = gid_Test_Brand_Dir_Program;
- Name = "cppunittester";
- Styles = (PACKED);
-End
-
-File gid_Test_File_Lib_Cppunit
- TXT_FILE_BODY;
- Styles = (PACKED);
- Dir = gid_Test_Brand_Dir_Program;
- #ifdef UNX
- Name = STRING(CONCAT3(libcppunit-1.13,UNXSUFFIX,.0));
- #endif
-End
-
-File gid_Test_File_Lib_Smoketest
- TXT_FILE_BODY;
- Styles = (PACKED);
- Dir = gid_Test_Brand_Dir_Program;
- #ifdef UNX
- Name = STRING(CONCAT2(libsmoketest,UNXSUFFIX));
- #endif
-End
-
-File gid_Test_File_Lib_Test
- TXT_FILE_BODY;
- Styles = (PACKED);
- Dir = gid_Test_Brand_Dir_Program;
- #ifdef UNX
- Name = STRING(CONCAT2(libtest,UNXSUFFIX));
- #endif
-End
-
-File gid_Test_File_Lib_Unotest
- TXT_FILE_BODY;
- Styles = (PACKED);
- Dir = gid_Test_Brand_Dir_Program;
- #ifdef UNX
- Name = STRING(CONCAT2(libunotest,UNXSUFFIX));
- #endif
-End
-
-File gid_Test_File_Lib_Unoexceptionprotector
- TXT_FILE_BODY;
- Styles = (PACKED);
- Dir = gid_Test_Brand_Dir_Program;
- #ifdef UNX
- Name = STRING(CONCAT2(unoexceptionprotector,UNXSUFFIX));
- #endif
-End
-
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/setup_native/Package_packinfo.mk b/setup_native/Package_packinfo.mk
index 945d3dc2e87e..d0678105508e 100644
--- a/setup_native/Package_packinfo.mk
+++ b/setup_native/Package_packinfo.mk
@@ -25,7 +25,6 @@ $(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_office.txt,
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_office_help.txt,packinfo_office_help.txt))
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_office_lang.txt,packinfo_office_lang.txt))
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_sdkoo.txt,packinfo_sdkoo.txt))
-$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_test.txt,packinfo_test.txt))
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/packinfo_ure.txt,packinfo_ure.txt))
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/shellscripts.txt,shellscripts.txt))
$(eval $(call gb_Package_add_file,setup_native/packinfo,bin/shellscripts_core01.txt,shellscripts_core01.txt))
diff --git a/setup_native/source/packinfo/packinfo_test.txt b/setup_native/source/packinfo/packinfo_test.txt
deleted file mode 100644
index 67dc0fa0927b..000000000000
--- a/setup_native/source/packinfo/packinfo_test.txt
+++ /dev/null
@@ -1,35 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-# This file incorporates work covered by the following license notice:
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed
-# with this work for additional information regarding copyright
-# ownership. The ASF licenses this file to you under the Apache
-# License, Version 2.0 (the "License"); you may not use this file
-# except in compliance with the License. You may obtain a copy of
-# the License at http://www.apache.org/licenses/LICENSE-2.0 .
-#
-
-Start
-module = "gid_Module_Root_Smoketest"
-solarispackagename = "%BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-smoketest"
-solarisrequires = "%BASISPACKAGEPREFIX%WITHOUTDOTPRODUCTVERSION-core01, SUNWbtool (Name="CCS tools bundled with SunOS"), SUNWxcu4 (Name="XCU4 Utilities")"
-packagename = "%BASISPACKAGEPREFIX%PRODUCTVERSION-smoketest"
-freebsdrequires = "%BASISPACKAGEPREFIX%PRODUCTVERSION-core01"
-requires = "%BASISPACKAGEPREFIX%PRODUCTVERSION-core01 %PACKAGEVERSION %PACKAGEVERSION"
-copyright = "2012 The Document Foundation"
-solariscopyright = "solariscopyrightfile"
-vendor = "The Document Foundation"
-description = "LibreOffice %PRODUCTVERSION Smoketest"
-destpath = "/opt"
-packageversion = "%PACKAGEVERSION"
-End
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/smoketest/Module_smoketest.mk b/smoketest/Module_smoketest.mk
index ab06c82a6067..798b7870f1e7 100644
--- a/smoketest/Module_smoketest.mk
+++ b/smoketest/Module_smoketest.mk
@@ -14,8 +14,6 @@ ifeq ($(CROSS_COMPILING),)
$(eval $(call gb_Module_add_targets,smoketest,\
Library_smoketest \
- Package_losmoketest \
- Package_smoketestdoc \
Zip_smoketestdoc \
))
diff --git a/smoketest/Package_losmoketest.mk b/smoketest/Package_losmoketest.mk
deleted file mode 100644
index b4634c68401d..000000000000
--- a/smoketest/Package_losmoketest.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-$(eval $(call gb_Package_Package,smoketest_losmoketest,$(SRCDIR)/smoketest))
-
-$(eval $(call gb_Package_add_file,smoketest_losmoketest,bin/losmoketest,losmoketest))
-
-# vim: set noet sw=4 ts=4:
diff --git a/smoketest/Package_smoketestdoc.mk b/smoketest/Package_smoketestdoc.mk
deleted file mode 100644
index cac1d6581061..000000000000
--- a/smoketest/Package_smoketestdoc.mk
+++ /dev/null
@@ -1,14 +0,0 @@
-# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-$(eval $(call gb_Package_Package,smoketestdoc,$(WORKDIR)/Zip))
-
-$(eval $(call gb_Package_add_file,smoketestdoc,bin/smoketestdoc.sxw,smoketestdoc.zip))
-
-# vim: set noet sw=4 ts=4:
diff --git a/smoketest/lodownloadtest.py b/smoketest/lodownloadtest.py
deleted file mode 100755
index 63ff439e2020..000000000000
--- a/smoketest/lodownloadtest.py
+++ /dev/null
@@ -1,662 +0,0 @@
-#!/usr/bin/env python
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-# The tool is designed to enable test machine fully automatically run smoketest
-# with both daily and pre release build located in dev-build.libreoffice.org.
-#
-# The tool is named as losmoketest for its purpose, meanwhile it help you to
-# check, download and install the latest build. By the fact the installation is
-# designed not to be different from manually doing these repeated work, the
-# installed libreoffice build can also be good for manual test.
-
-import sys, os, platform
-import datetime, time
-import subprocess, shutil
-import glob, re
-import urllib, urllib2
-import logging, getopt
-try:
- import ConfigParser as configparser # Python 3.0 change
-except ImportError:
- import configparser
-
-# FIXME: make this configurable via options or autodetect it
-build_version = "3.5"
-tag_version = "3-5"
-# devel build
-branding_pack="lodev"
-basis_pack="lodevbasis"
-# stable build
-#branding_pack="libreoffice"
-#basis_pack="libobasis"
-
-# possible program files of libreoffice, put all platform paths are
-# expected in this list
-lo_all_paths = [
- "/opt/lodev" + build_version, \
- "/opt/libreoffice" + build_version, \
- "/usr/lib/libreoffice", \
- "/usr/lib64/libreoffice", \
- "C:\program file\libreoffice", \
- ]
-
-build_check_interval = 5 #seconds
-
-# Distro list
-RPM_DISTRO_LIST = ['SuSE', 'fedora', 'redhat', 'centos', 'mandrake', 'mandriva', 'yellowdog', 'turbolinux']
-DEB_DISTRO_LIST = ['debian', 'ubuntu', 'Ubuntu']
-
-# Server urls
-SERVER_URL = "http://dev-builds.libreoffice.org"
-
-# Local dirs
-root_dir = os.getcwd()
-DOWNLOAD_DIR = os.path.join(root_dir, "_download")
-USR_DIR = os.path.join(root_dir, "_libo_smoke_user")
-LOCAL_BUILD_INFO_FILE = os.path.join(root_dir, "build.cfg")
-
-# INSTALL_DIR = os.path.join(root_dir, "_libo_smoke_installation")
-INSTALL_DIR = "" # Installation dir
-
-# SOFFICE_BIN bin
-if platform.system() == "Linux":
- SOFFICE_BIN = "soffice"
- LOSMOKETEST_BIN = "losmoketest"
-elif platform.system() == "Windows":
- SOFFICE_BIN = "soffice.exe"
- LOSMOKETEST_BIN = "losmoketest"
-else:
- SOFFICE_BIN = "soffice"
- LOSMOKETEST_BIN = "losmoketest"
-
-# Relative build url
-## pre-releases
-PR_RPM_X86_PATH = "pre-releases/rpm/x86/"
-PR_RPM_X86_64_PATH = "pre-releases/rpm/x86_64/"
-
-PR_DEB_X86_PATH = "pre-releases/deb/x86/"
-PR_DEB_X86_64_PATH = "pre-releases/deb/x86_64/"
-
-PR_MAC_X86_PATH = "pre-releases/mac/x86/"
-PR_MAC_PPC_PATH = "pre-releases/mac/ppc/"
-
-PR_WIN_X86_PATH = "pre-releases/win/x86/"
-
-## daily_master
-DAILY_MASTER_RPM_X86_PATH = "daily/Linux-x86_10-Release_Configuration/master/current"
-DAILY_MASTER_RPM_X86_64_PATH = "daily/Linux-x86_64_11-Release_Configuration/master/current"
-
-DAILY_MASTER_DEB_X86_PATH = "daily/Linux-x86_10-Release_Configuration/master/current"
-DAILY_MASTER_DEB_X86_64_PATH = "daily/Linux-x86_64_11-Release_Configuration/master/current"
-
-DAILY_MASTER_MAC_X86_PATH = "daily/MacOSX-Intel@3-OSX_10.6.0-gcc_4.0.1/master/current"
-DAILY_MASTER_MAC_PPC_PATH = "daily/MacOSX-PPC@12-OSX_10.5.0-gcc_4.0.1/master/current" # No build yet
-
-DAILY_MASTER_WIN_X86_PATH = "daily/Win-x86@7-MinGW/master/current" # cross compling build
-
-## daily_branch
-DAILY_BRANCH_RPM_X86_PATH = "daily/Linux-x86_10-Release_Configuration/libreoffice-" + tag_version + "/current"
-DAILY_BRANCH_RPM_X86_64_PATH = "daily/Linux-x86_64_11-Release_Configuration/libreoffice-" + tag_version + "/current"
-
-DAILY_BRANCH_DEB_X86_PATH = "daily/Linux-x86_10-Release_Configuration/libreoffice-" + tag_version + "/current"
-DAILY_BRANCH_DEB_X86_64_PATH = "daily/Linux-x86_64_11-Release_Configuration/libreoffice-" + tag_version + "/current"
-
-DAILY_BRANCH_MAC_X86_PATH = "daily/MacOSX-Intel@3-OSX_10.6.0-gcc_4.0.1/libreoffice-" + tag_version + "/current"
-DAILY_BRANCH_MAC_PPC_PATH = "daily/MacOSX-PPC@12-OSX_10.5.0-gcc_4.0.1/libreoffice-" + tag_version + "/current"
-
-DAILY_BRANCH_WIN_X86_PATH = "daily/Win-x86@7-MinGW/libreoffice-" + tag_version + "/current"
-
-
-
-def platform_info():
-
- s = platform.system()
- arch_name = platform.machine()
-
- if arch_name in ['x86', 'i386', 'i586', 'i686']:
- arch_name = 'x86'
-
- if s == "Linux":
- if platform.dist()[0] in RPM_DISTRO_LIST:
- distro_name = platform.dist()[0]
- pck_name = 'rpm'
- elif platform.dist()[0] in DEB_DISTRO_LIST:
- distro_name = platform.dist()[0]
- pck_name = 'deb'
- elif s == "Windows":
- distro_name = platform.dist()[0]
- pck_name = 'exe'
- else:
- distro_name = platform.dist()[0]
- pck_name = 'dmg'
-
- return distro_name, pck_name, arch_name
-
-def local_build_info(t):
-
- if not os.path.exists(LOCAL_BUILD_INFO_FILE):
- logger.error("Can't find the file: " + LOCAL_BUILD_INFO_FILE)
- sys.exit()
-
- config = configparser.RawConfigParser()
- config.read(LOCAL_BUILD_INFO_FILE)
-
- try:
- build_name = config.get(t, 'build_name').strip('\n')
- build_time = datetime.datetime.strptime(config.get(t, 'build_time').strip('\n'), '%d-%b-%Y %H:%M')
- except ValueError:
- build_name = ''
- build_time = datetime.datetime.min
-
- try:
- testpack_name = config.get(t, 'testpack_name').strip('\n')
- testpack_build_time = datetime.datetime.strptime(config.get(t, 'testpack_build_time').strip('\n'), '%d-%b-%Y %H:%M')
- except ValueError:
- testpack_name = ''
- testpack_build_time = datetime.datetime.min
-
- return build_name, build_time, testpack_name, testpack_build_time
-
-def get_url_regexp(t, package, arch):
- '''
- return a url containing download links, i.e:
-
- http://dev-builds.libreoffice.org/pre-releases/rpm/x86_64/
- http://dev-builds.libreoffice.org/daily/Windows_Release_Configuration/libreoffice-3-4/current/
- http://dev-builds.libreoffice.org/daily/Linux_x86_Release_Configuration/libreoffice-3-4/current/
-
- meanwhile return a regexp object that matching corresponding downloadable
- package and its timestamp '''
-
- url = ""
- reg_lo = re.compile('^$')
- reg_tst = re.compile('^$')
- pck = package
- arc = arch
-
- if t == 'pre-releases':
- if pck == "rpm" and arc == "x86":
- url = SERVER_URL + "/" + PR_RPM_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*x86_install-rpm.*en-US.*\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- reg_tst = re.compile('\<a\ href=\"(LibO-Test.*.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "rpm" and arc == "x86_64":
- url = SERVER_URL + "/" + PR_RPM_X86_64_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*x86-64_install-rpm.*en-US.*\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- reg_tst = re.compile('\<a\ href=\"(LibO-Test.*.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86":
- url = SERVER_URL + "/" + PR_DEB_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*x86_install-deb.*en-US.*\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86_64":
- url = SERVER_URL + "/" + PR_DEB_X86_64_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*x86-64_install-deb.*en-US.*\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "exe" and arc == "x86":
- url = SERVER_URL + "/" + PR_WIN_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*Win_x86_install_multi.exe)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "dmg" and arc == "x86":
- url = SERVER_URL + "/" + PR_MAC_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*MacOS_x86_install_en-US.dmg)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "dmg" and arc == "ppc":
- url = SERVER_URL + "/" + PR_MAC_PPC_PATH
- reg_lo = re.compile('\<a\ href=\"(LibO_\d.*MacOS_PPC_install_en-US.dmg)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- else:
- logger.error("Unable to handle the system or arch!")
- elif t == 'daily_master':
- if pck == "rpm" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_MASTER_RPM_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(master\~\d.*LibO-Dev_.*x86_install-rpm_en-US.tar.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "rpm" and arc == "x86_64":
- url = SERVER_URL + "/" + DAILY_MASTER_RPM_X86_64_PATH
- reg_lo = re.compile('\<a\ href=\"(master\~\d.*LibO-Dev_.*x86-64_install-rpm_en-US.tar.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_MASTER_DEB_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(master\~\d.*LibO-Dev_.*x86_install-deb_en-US.tar.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86_64":
- url = SERVER_URL + "/" + DAILY_MASTER_DEB_X86_64_PATH
- reg_lo = re.compile('^$') # No build yet
- elif pck == "exe" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_MASTER_WIN_X86_PATH
- reg_lo = re.compile('^$') # No build yet
- elif pck == "dmg" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_MASTER_MAC_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(master\~\d.*LibO-Dev_.*x86_install_en-US.dmg)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "dmg" and arc == "ppc":
- url = SERVER_URL + "/" + DAILY_MASTER_MAC_PPC_PATH
- reg_lo = re.compile('^$') # No build yet
- else:
- logger.error("Unable to handle the system or arch!")
- elif t == 'daily_branch':
- if pck == "rpm" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_BRANCH_RPM_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(.*LibO_.*x86_install-rpm_en-US\.tar\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "rpm" and arc == "x86_64":
- url = SERVER_URL + "/" + DAILY_BRANCH_RPM_X86_64_PATH
- reg_lo = re.compile('\<a\ href=\"(.*LibO_.*x86-64_install-rpm_en-US\.tar\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_BRANCH_DEB_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(.*LibO_.*x86_install-deb_en-US\.tar\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "deb" and arc == "x86_64":
- url = SERVER_URL + "/" + DAILY_BRANCH_DEB_X86_64_PATH
- reg_lo = re.compile('\<a\ href=\"(.*LibO_.*x86-64_install-deb_en-US\.tar\.gz)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "exe" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_BRANCH_WIN_X86_PATH
- reg_lo = re.compile('\<a\ href=\"(.*LibO_.*install_.*\.exe)\".*(\d{2}\-[a-zA-Z]{3}\-\d{4}).*(\d{2}:\d{2}).*')
- elif pck == "dmg" and arc == "x86":
- url = SERVER_URL + "/" + DAILY_BRANCH_MAC_X86_PATH
- reg_lo = re.compile('^$') # No build yet
- elif pck == "dmg" and arc == "ppc":
- url = SERVER_URL + "/" + DAILY_BRANCH_MAC_PPC_PATH
- reg_lo = re.compile('^$') # No build yet
- else:
- logger.error("Unable to handle the system or arch!")
- else:
- logger.error("Error build type! The build type has to be:\n pre-releases, daily_master, daily_branch")
-
- return url, reg_lo, reg_tst
-
-def remote_build_info(url_reg):
- ''' Get the latest proper build info (build_name, build_time) from
- url. '''
-
- p = platform_info()
- pck = p[1]
- arc = p[2]
- r = url_reg[1]
- r_t = url_reg[2]
-
- f = urllib2.urlopen(url_reg[0])
- c = ''.join(f.readlines())
- f.close()
-
- build_list = r.findall(c)
- test_list = r_t.findall(c)
-
- build_name = ''
- build_time = datetime.datetime.min
- testpack_build_time = datetime.datetime.min
- testpack_name = ''
-
-
- for b in build_list:
- if datetime.datetime.strptime(b[1] + ' ' + b[2], '%d-%b-%Y %H:%M') > build_time:
- build_name = b[0]
- try:
- build_time = datetime.datetime.strptime(b[1] + ' ' + b[2], '%d-%b-%Y %H:%M')
- except:
- print "remote_build_info: wrong time date&format"
-
- for t in test_list:
- if datetime.datetime.strptime(t[1] + ' ' + t[2], '%d-%b-%Y %H:%M') > testpack_build_time:
- testpack_name = t[0]
- try:
- testpack_build_time = datetime.datetime.strptime(t[1] + ' ' + t[2], '%d-%b-%Y %H:%M')
- except:
- print "remote_build_info: wrong time date&format"
-
- return build_name, build_time, testpack_name, testpack_build_time
-
-# return True when something was downloaded
-def download(url_reg, build_type):
- logger.info('Checking new build ...')
-
- try:
- remote_build = remote_build_info(url_reg)
- local_build = local_build_info(build_type)
-
- if remote_build[1] > local_build[1]:
- logger.info('Found New LO build: ' + remote_build[0])
- if fetch_build(url_reg[0], remote_build[0]):
- set_build_config(build_type, 'build_name', remote_build[0])
- set_build_config(build_type, 'build_time', datetime.datetime.strftime(remote_build[1], '%d-%b-%Y %H:%M'))
- else:
- logger.error('Download libreoffice build failed!')
-
- if remote_build[3] > local_build[3] and (remote_build[1] - remote_build[3]) < datetime.timedelta(hours=1):
- logger.info('Found a relevant smoketest package: ' + remote_build[2])
- if fetch_build(url_reg[0], remote_build[2]):
- set_build_config(build_type, 'testpack_name', remote_build[2])
- set_build_config(build_type, 'testpack_build_time', datetime.datetime.strftime(remote_build[3], '%d-%b-%Y %H:%M'))
- return True
- else:
- logger.warning("Failed to find corresponding smoketest package")
-
- except urllib2.URLError, HTTPError:
- logger.error('Error fetch remote build info.')
- return False
- except KeyboardInterrupt:
- sys.exit()
- except:
- logger.error('Error fetch remote build info.')
- return False
-
- return False
-
-def fetch_build(url, filename):
- ''' Download a build from address url/filename '''
-
- logger.info("Downloading ... " + filename)
-
- u = urllib2.urlopen(url + '/' + filename)
-
- try:
- f = open(DOWNLOAD_DIR + '/' + filename, 'wb')
- f.write(u.read())
- f.close()
- except urllib2.HTTPError, e:
- print "HTTP Error:",e.code , url
- except urllib2.URLError, e:
- print "URL Error:",e.reason , url
-
- return True
-
-def set_build_config(section, option, value):
-
- config = configparser.RawConfigParser()
- config.readfp(open(LOCAL_BUILD_INFO_FILE))
- config.set(section, option, value)
- with open(LOCAL_BUILD_INFO_FILE, 'wb') as cfgfile:
- config.write(cfgfile)
-
-def uninstall(build_type):
- ''' Kill libreoffice processes and uninstall all previously installed
- libreoffice packages '''
-
- if build_type == "pre-releases":
- branding_pack="libreoffice"
- basis_pack="libobasis"
-
- logger.info("Uninstalling ...")
-
- pck = platform_info()[1]
-
- if pck == 'rpm':
- cmd_query = ["rpm", "-qa"]
- cmd_filter = ["grep", \
- "-e", branding_pack+build_version, \
- "-e", basis_pack+build_version, \
- ]
-
- P_query = subprocess.Popen(cmd_query, stdout = subprocess.PIPE)
- P_filter = subprocess.Popen(cmd_filter, stdin = P_query.stdout, stdout = subprocess.PIPE)
- P_query.stdout.close() # protection when P_filter exit before P_query
- str_filter = P_filter.communicate()[0]
-
- if str_filter == "":
- logger.warning("Nothing to uninstall")
- return
- else:
- cmd = ["sudo", "rpm", "-e"] + str_filter.split()
- elif pck == 'deb':
- cmd_query = ["dpkg", "--get-selections", branding_pack+build_version+"*", basis_pack+build_version+"*"]
- cmd_filter = ["cut", "-f", "1"]
-
- P_query = subprocess.Popen(cmd_query, stdout = subprocess.PIPE)
- P_filter = subprocess.Popen(cmd_filter, stdin = P_query.stdout, stdout = subprocess.PIPE)
- P_query.stdout.close()
- str_filter = P_filter.communicate()[0]
-
- if str_filter == "":
- logger.warning("Nothing to uninstall")
- return
- else:
- cmd = ["sudo", "dpkg ", "-P"] + str_filter.split()
- elif pck == 'exe':
- pass
- elif pck == 'dmg':
- pass
- else:
- logger.warning("Non supported package system")
-
- subprocess.check_call(cmd)
-
-def init_testing():
- logger.info("Initializing ...")
-
- post_testing()
-
- if not os.path.exists(DOWNLOAD_DIR):
- os.mkdir(DOWNLOAD_DIR)
-
- if not os.path.exists(USR_DIR):
- os.mkdir(USR_DIR)
-
- if not os.path.exists(LOCAL_BUILD_INFO_FILE):
-
- init_build_cfg = '[daily_branch]' + os.linesep\
- + 'build_name =' + os.linesep\
- + 'build_time =' + os.linesep\
- + 'testpack_name =' + os.linesep\
- + 'testpack_build_time =' + os.linesep\
- + '[daily_master]' + os.linesep\
- + 'build_name =' + os.linesep\
- + 'build_time =' + os.linesep\
- + 'testpack_name =' + os.linesep\
- + 'testpack_build_time =' + os.linesep\
- + '[pre-releases]' + os.linesep\
- + 'build_name =' + os.linesep\
- + 'build_time =' + os.linesep \
- + 'testpack_name =' + os.linesep\
- + 'testpack_build_time =' + os.linesep
-
- with open(LOCAL_BUILD_INFO_FILE, 'w+') as f:
- f.write(init_build_cfg)
- f.close()
-
-def post_testing():
- logger.info("Cleaning up ...")
-
- # clean up the extracted installer dir
- for r in os.walk(DOWNLOAD_DIR):
- if r[0] == DOWNLOAD_DIR:
- for d in r[1]:
- shutil.rmtree(os.path.join(r[0], d))
-
-def install(filename):
- ''' filename: local file path of tar.gz, dmg or exe. The script will
- extract the package and then install it '''
-
- logger.info("Installing ... " + filename)
-
- def _is_not_filtered(s):
- ''' True if the package s is not intended to installed. '''
- filter_pattern_list = ['.*kde.*', '.*gnome.*', '.*desktop.*', '!.*\.rpm$', '!.*\.deb$']
- for p in filter_pattern_list:
- r = re.compile(p)
- if r.match(s):
- return False
- return True
-
- fn, ext = os.path.splitext(filename)
- pcklist = []
-
- if ext == '.exe':
- # extract
- installer_dir = os.path.join(DOWNLOAD_DIR, filename.strip(ext))
- subprocess.check_call([filename, '/EXTRACTONLY=ON', '/S', '/D='+installer_dir])
- # install
- installer = glob.glob(os.path.join(installer_dir, 'libreoffice*msi'))[0]
- subprocess.check_call(['msiexec', '-i', installer, '-passive', 'ADDLOCAL=all'])
- elif ext == '.dmg':
- return
- elif ext == '.gz':
- # extract
- subprocess.check_call(['tar', 'xzf', filename, '-C', DOWNLOAD_DIR])
-
- # get a filtered install list
- for root, dirs, files in os.walk(DOWNLOAD_DIR):
- if 'RPMS' in root or 'DEBS' in root:
- pcklist = pcklist + [os.path.join(root_dir, root, f) for f in files]
- install_pcklist = filter(_is_not_filtered, pcklist)
-
- # install
- if platform_info()[1] == 'rpm':
- install_cmd = ["sudo", "rpm", "-iv"] + install_pcklist
- clean_tmp_cmd = ["sudo", "rm", "-f"] + pcklist
- elif platform_info()[1] == 'deb':
- install_cmd = ["sudo", "dpkg", "-i"] + install_pcklist
- else:
- logger.error('Cannot generate install command')
- return
-
- subprocess.check_call(install_cmd)
- subprocess.check_call(clean_tmp_cmd)
-
- else:
- logger.info("Unrecognized file extension")
-
-def verify_smoketest(headless):
- logger.info("Testing ...")
-
- s = platform.system()
- p = platform_info()
- pck = p[1]
- arc = p[2]
-
- lo_testable_paths = filter(lambda p: \
- os.path.exists(p + os.sep + "program" + os.sep + LOSMOKETEST_BIN) and \
- os.path.exists(p + os.sep + "program" + os.sep + SOFFICE_BIN), \
- lo_all_paths)
-
- if not lo_testable_paths:
- logger.error("Not found any Libreoffice or Test packages!")
- sys.exit(1)
- else:
- cmd_smoketests = [ p + os.sep + "program" + os.sep + LOSMOKETEST_BIN for p in lo_testable_paths ]
-
- if len(lo_testable_paths) > 1:
- logger.info("++More than one testable build is found, test them one by one.")
-
- # subprocess.call(cmd_smoketest);
- for c in cmd_smoketests:
- pattern = re.compile(LOSMOKETEST_BIN + "$")
- logger.info(" Test Binary: " + pattern.sub(SOFFICE_BIN, c))
- subprocess.call(c)
-
-def usage():
-
- print "\n[Usage]\n\n -f Force testing without asking \n\
- -t Testing type pre-release/daily \n\
- -l Download and test last builds in a loop \n\
- -v Run smoketest verification directly \n\
- -s Use the headless mode when running the tests \n\
- -i Install the latest build in the DOWNLOAD directory \n\
- -u Uninstall any existed libreoffice build \n\
- -d Download the latest build for the given test type \n\
-"
-
-def main():
-
- interactive = True
- build_type = "pre-releases"
-
- package_type = platform_info()[1]
- arch_type = platform_info()[2]
-
- loop = False
- interactive = True
- headless = False
- build_type = "pre-releases"
-
- # Handling options and arguments
- try:
- opts, args = getopt.getopt(sys.argv[1:], "dluihfvst:", ["download", "loop", "uninstall", "install", "help", "force", "verify", "headless", "type="])
- except getopt.GetoptError, err:
- logger.error(str(err))
- usage()
- sys.exit(2)
-
- for o, a in opts:
- if ("-t" in o) or ("--type" in o):
- build_type = a
- elif o in ("-s", "--headless"):
- headless = True
-
- url_reg = get_url_regexp(build_type, package_type, arch_type)
-
- for o, a in opts:
- if o in ("-f", "--force"):
- interactive = False
- elif o in ("-t", "--type"):
- pass
- elif o in ("-s", "--headless"):
- pass
- elif o in ("-h", "--help"):
- usage()
- sys.exit()
- elif o in ("-v", "--verify"):
- init_testing()
- verify_smoketest(headless)
- sys.exit()
- elif o in ("-i", "--install"):
- init_testing()
- uninstall(build_type)
- install(DOWNLOAD_DIR + os.sep + local_build_info(build_type)[0])
- install(DOWNLOAD_DIR + os.sep + local_build_info(build_type)[2])
- sys.exit()
- elif o in ("-u", "--uninstall"):
- uninstall(build_type)
- sys.exit()
- elif o in ("-d", "--download"):
- init_testing()
- download(url_reg, build_type)
- sys.exit()
- elif o in ("-l", "--loop"):
- loop = True
- else:
- assert False, "Unhandled option: " + o
-
- if interactive == True:
- key = raw_input("The testing will OVERRIDE existed libreoffice, continue(y/N)? ")
- if not (key == "y" or key == "Y" or key == "yes"):
- sys.exit()
-
- init_testing()
- first_run = True
- while loop or first_run:
- if download(url_reg, build_type):
- try:
- # FIXME: uninstall script fails but it need not break the whole game; so try it twice
- try:
- uninstall(build_type)
- except:
- logger.error("Some errors happened during uninstall. Trying once again.")
- uninstall(build_type)
-
- install(DOWNLOAD_DIR + os.sep + local_build_info(build_type)[0])
- install(DOWNLOAD_DIR + os.sep + local_build_info(build_type)[2])
- verify_smoketest(headless)
-
- except KeyboardInterrupt:
- sys.exit()
- except:
- continue
- else:
- logger.warning("No new build found.")
- if loop:
- time.sleep(build_check_interval)
-
- first_run = False
-
-
-if __name__ == '__main__':
-
- # logging
- logger = logging.getLogger('')
- logger.setLevel(logging.DEBUG)
-
- fh = logging.FileHandler(os.path.basename(__file__) + '.log')
- ch = logging.StreamHandler()
-
- formatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s')
- ch.setFormatter(formatter)
- fh.setFormatter(formatter)
-
- logger.addHandler(ch)
- logger.addHandler(fh)
-
- main()
diff --git a/smoketest/losmoketest b/smoketest/losmoketest
deleted file mode 100755
index d43a178731fa..000000000000
--- a/smoketest/losmoketest
+++ /dev/null
@@ -1,41 +0,0 @@
-#!/bin/sh
-#
-# This file is part of the LibreOffice project.
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-#
-
-# resolve installation directory
-sd_cwd=`pwd`
-sd_res=$0
-while [ -h "$sd_res" ] ; do
- cd "`dirname "$sd_res"`"
- sd_basename=`basename "$sd_res"`
- sd_res=`ls -l "$sd_basename" | sed "s/.*$sd_basename -> //g"`
-done
-cd "`dirname "$sd_res"`"
-sd_prog=`pwd`
-cd "$sd_cwd"
-
-user_conf_dir=`grep UserInstallation $sd_prog/bootstraprc | sed -e "s|UserInstallation=||" -e "s|\\$SYSUSERCONFIG|$HOME/.config|"`
-
-case "`uname -s`" in
-Linux)
- sd_prog1="$sd_prog"
- sd_prog2="$sd_prog/../ure/lib"
- LD_LIBRARY_PATH=$sd_prog1:$sd_prog2${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
- export LD_LIBRARY_PATH
- ;;
-esac
-
-exec $sd_prog/cppunittester \
- -env:UNO_SERVICES=file://$sd_prog/../ure/share/misc/services.rdb \
- -env:UNO_TYPES=file://$sd_prog/../ure/share/misc/types.rdb\ file://$sd_prog/types/offapi.rdb \
- -env:arg-soffice=path:$sd_prog/soffice \
- -env:arg-user=$user_conf_dir \
- -env:arg-env=$LD_LIBRARY_PATH \
- -env:arg-testarg.smoketest.doc=$sd_prog/../share/test/smoketestdoc.sxw \
- --protector $sd_prog/unoexceptionprotector.so unoexceptionprotector \
- $sd_prog/libsmoketest.so
diff --git a/smoketest/losmoketest.readme b/smoketest/losmoketest.readme
deleted file mode 100644
index 88091339d8d6..000000000000
--- a/smoketest/losmoketest.readme
+++ /dev/null
@@ -1,186 +0,0 @@
-losmoketest.py
---------------
-Yifan Jiang <yfjiang@suse.com>
-http://dev-builds.libreoffice.org/
-
-The tool is designed to enable test machine fully automatically run smoketest
-with both daily and pre release build located in dev-build.libreoffice.org.
-
-The purpose of daily build testing is obvious, we want to catch bugs as early
-as possible:) some ideas canbe found here:
-
- http://wiki.documentfoundation.org/Testing_Daily_Builds#Is_parallel_installation_possible_.2F_planned.3F
-
-For the purpose of smoketest for pre release testing, currently there is an
-about 24 hrs lag syncing RC build from dev-build to official site. We need to
-guarantee at least the very basic function working before more people download
-the RC build from official site and play with it, in as short as 24 hrs.
-
-The tool is named as losmoketest for its purpose, meanwhile it help you to
-check, download and install the latest build. By the fact the installation is
-designed not to be different from manually doing these repeated work, the
-installed libreoffice build can also be good for manual test.
-
-Quick Start
------------
-
-This chapter describe step by step tutorials for a typical quick use of the
-tool. More functions can be discovered in section "The Tool -> Usage".
-
-[Linux]
-
- 0. If you do not have a python environment, firstly download python here:
-
- http://www.python.org/download/
-
- 1. Download binary:
-
- http://dev-builds.libreoffice.org/daily/losmoketest-0.2.tar.bz2
-
- 2. Unpack it to, for example, your home directory:
-
- tar xvjf losmoketest-0.2.tar.bz2 -C $HOME
-
- 3. Open a terminal
-
- 4. In the terminal, input (there's an Enter between each lines):
-
- su -
- (enter your root password when it prompts)
- cp /etc/sudoers /etc/sudoers.ori
- echo "$USER ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
- exit
-
- 5. In the terminal, input (there's an Enter between each lines):
-
- cd $HOME/losmoketest-0.2
- python ./losmoketest.py
-
- A msg OK(1) would be shown When the result successfully
- finished. Otherwise, please send the 'log' file to the author or mailing
- list libreoffice-qa@lists.freedesktop.org for more investigation.
-
- 6. After finish testing, recover the sudoers file by (there's an Enter
- between each lines),
-
- su -
- (enter your root password)
- cp /etc/sudoers.ori /etc/sudoers
- exit
-
-[Windows]
-
- 0. If you do not have a python environment, firstly download python here:
-
- http://www.python.org/download/
-
- 1. Download binary:
-
- http://dev-builds.libreoffice.org/daily/losmoketest-0.2.tar.bz2
-
- 2. Unpack it to, for example, C:\
-
- 3. Open a console by clicking Start menu -> Run ...
-
- 4. Input 'cmd' and press Enter
-
- 5. In the terminal, input (there's an Enter between each lines):
-
- cd C:\losmoketest-0.2
- .\losmoketest.py
-
- A msg OK(1) would be shown When the result successfully
- finished. Otherwise, please send the 'log' file to the author or mailing
- list libreoffice-qa@lists.freedesktop.org for more investigation.
-
-
-The tool
---------
-
-[Prerequisite]
-
- - Python > 2.6
- http://www.python.org/download/
-
- - A machine free to play (The test may *override* your existed
- libreoffice3.4 installation).
-
- - On Linux, add the following line in /etc/sudoer:
-
- $USER ALL=(ALL) NOPASSWD: ALL
-
- where $USER is your real user name. With this line, every command
- initialed with `sudo` will not be asked to input a password. Please
- consider the security risk brought by it.
-
-[Features Availability]
-
- Full features are implemented on Linux x86 and x86_64, rpm and deb:
-
- - Checking and dowloading the latest build
- - Install the latest build
- - Run smoke test on the build (not stable)
-
- Partial features are implemented on Windows:
-
- - Checking and dowloading the latest build
- - Install the latest build (Thanks *blip* help find out the command for silent install)
-
- Partial features are implemented on Mac:
-
- - Checking and dowloading the latest build
-
-[Usages]
-
- 1. Test the latest pre releases build:
-
- $ cd /path/to/losmoketest
- $ ./losmoketest.py # Test the latest pre releases build:
- $ ./losmoketest.py -t daily_master # Test the latest daily master build
- $ ./losmoketest.py -t daily_branch # Test the latest daily branch build (now 3.4)
-
- 2. Just Install the latest LOCAL build:
-
- $ cd /path/to/losmoketest
- $ ./losmoketest.py -i # Install the latest pre releases build in losmoketest/_download
- $ ./losmoketest.py -i -t daily_master # Install the latest daily master build in losmoketest/_download
- $ ./losmoketest.py -i -t daily_branch # Install the latest daily branch build (now 3.4) in losmoketest/_download
-
- 3. Just Verify the installed build:
-
- $ cd /path/to/losmoketest
- $ ./losmoketest.py -v
-
- 4. More tips in:
-
- $ cd /path/to/losmoketest
- $ ./losmoketest.py -h
-
-[Tested on]
-
- - SLED 11 sp1 x86
- - SLED 11 sp1 x86_64
- - OpenSuSE 11.4 x86
- - Ubuntu 10.10 x86
-
-[TODO]
-
- 1. verify_smoketest() improvement (replace it with more simple script
- rather than complicated cppunittester)
-
- 2. 'git' it when we have a stable code base
-
- 3. handling mac and windows build
-
-[Known issue]
-
- 1. The cppunittest performs not quite stable in different libreoffice
- build, some times it just hangs there without noticing :(
-
- 2. The version tag is desired to get dynamically. The current hard coded
- 3.4 is not reliable, especially not reliable when verify_smoketest()
- tries to set LD_LIBRARY_PATH.
-
- 3. Parallel installation with official build has a dependancy on Tinderbox
- improvement (the dev-build is ideally to be installed on something like
- /opt/lo-dev).