diff options
Diffstat (limited to 'testautomation/extensions')
149 files changed, 3994 insertions, 0 deletions
diff --git a/testautomation/extensions/optional/e_display_name.bas b/testautomation/extensions/optional/e_display_name.bas new file mode 100755 index 000000000000..61c57458b374 --- /dev/null +++ b/testautomation/extensions/optional/e_display_name.bas @@ -0,0 +1,57 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension display names +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\display_name.inc" + + call hStatusIn( "extensions" , "e_display_name.bas" ) + call tExtensionDisplayName() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_extensions.bas b/testautomation/extensions/optional/e_extensions.bas new file mode 100755 index 000000000000..2ea2a68a0ef5 --- /dev/null +++ b/testautomation/extensions/optional/e_extensions.bas @@ -0,0 +1,54 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/************************************************************************ +'* +'* owner : thorsten.bosbach@sun.com +'* +'* short description : Function test of extension manager +'* +'\************************************************************************ + +sub main + use "extensions\optional\includes\extensions.inc" + + call hStatusIn ( "extensions","e_extensions.bas" ) + + printlog " function test of extension manager " + + call tExtensionsFunction() + + call hStatusOut +end sub + +'------------------------------------------------------------------------- +sub LoadIncludeFiles + use "global\system\includes\master.inc" + use "global\system\includes\gvariabl.inc" + gApplication = "WRITER" + call GetUseFiles +end sub +'------------------------------------------------------------------------- + diff --git a/testautomation/extensions/optional/e_fileopen.bas b/testautomation/extensions/optional/e_fileopen.bas new file mode 100755 index 000000000000..3cc2ea374869 --- /dev/null +++ b/testautomation/extensions/optional/e_fileopen.bas @@ -0,0 +1,55 @@ +'encoding UTF-8 Do not remove or change this line! +'******************************************************************************* +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : CWS oxtsysint01 enables installing extensions via file open dialog +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\fileopen.inc" + + call hStatusIn( "extensions" , "e_fileopen.bas" ) + call tExtensionFileOpen() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + use "global\tools\includes\optional\t_extension_manager_tools.inc" + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_help.bas b/testautomation/extensions/optional/e_help.bas new file mode 100755 index 000000000000..3f18db86689d --- /dev/null +++ b/testautomation/extensions/optional/e_help.bas @@ -0,0 +1,57 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extensible help +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\help.inc" + + call hStatusIn( "extensions" , "e_help.bas" ) + call tExtensibleHelp() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_identifiers.bas b/testautomation/extensions/optional/e_identifiers.bas new file mode 100755 index 000000000000..526447987d2e --- /dev/null +++ b/testautomation/extensions/optional/e_identifiers.bas @@ -0,0 +1,59 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Use unique identifiers instead of filenames for extensions +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\identifiers.inc" + + call hStatusIn( "extensions" , "e_identifiers.bas" ) + call tExtensionIdentifiers() + call hStatusOut() + +end sub + +'------------------------------------------------------------------------- + +sub LoadIncludeFiles + + use "global\system\includes\master.inc" + use "global\system\includes\gvariabl.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + use "global\tools\includes\optional\t_treelist_tools.inc" + use "global\tools\includes\optional\t_docfuncs.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_location.bas b/testautomation/extensions/optional/e_location.bas new file mode 100755 index 000000000000..bec66a615c99 --- /dev/null +++ b/testautomation/extensions/optional/e_location.bas @@ -0,0 +1,68 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Test the extension locator service +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\location.inc" + + call hStatusIn( "extensions" , "e_location.bas" ) + + hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_MEDIUM ) + + call tExtensionLocation() + + hSetMacroSecurityAPI( GC_MACRO_SECURITY_LEVEL_DEFAULT ) + + call hStatusOut() + +end sub + +'------------------------------------------------------------------------- + +sub LoadIncludeFiles + + use "global\system\includes\master.inc" + use "global\system\includes\gvariabl.inc" + + use "global\tools\includes\optional\t_docfuncs.inc" + use "global\tools\includes\optional\t_filetools.inc" + use "global\tools\includes\optional\t_macro_tools.inc" + use "global\tools\includes\optional\t_security_tools.inc" + use "global\tools\includes\optional\t_treelist_tools.inc" + use "global\tools\includes\optional\t_extension_manager_tools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_meta-inf.bas b/testautomation/extensions/optional/e_meta-inf.bas new file mode 100755 index 000000000000..7eb96001aed0 --- /dev/null +++ b/testautomation/extensions/optional/e_meta-inf.bas @@ -0,0 +1,59 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Case sensitive META-INF file +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\meta-inf.inc" + + call hStatusIn( "extensions" , "e_meta-inf.bas" ) + call tLowerCaseMetaInf + call hStatusOut() + +end sub + +'------------------------------------------------------------------------- + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + use "global\tools\includes\optional\t_extension_manager_tools.inc" + + use "global\tools\includes\optional\t_docfuncs.inc" + use "global\tools\includes\optional\t_filetools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_online_update.bas b/testautomation/extensions/optional/e_online_update.bas new file mode 100755 index 000000000000..f0f63c3514ed --- /dev/null +++ b/testautomation/extensions/optional/e_online_update.bas @@ -0,0 +1,57 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Hit update button for an extension +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\online_update.inc" + + call hStatusIn( "extensions" , "e_online_update.bas" ) + call tExtensionUpdate() + call hStatusOut() + +end sub + +'------------------------------------------------------------------------- + +sub LoadIncludeFiles + + use "global\system\includes\master.inc" + use "global\system\includes\gvariabl.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_options.bas b/testautomation/extensions/optional/e_options.bas new file mode 100755 index 000000000000..97126a333bb8 --- /dev/null +++ b/testautomation/extensions/optional/e_options.bas @@ -0,0 +1,59 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Options for extensions +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\options.inc" + + call hStatusIn( "extensions" , "e_options.bas" ) + call tExtensionOptions1() + call hStatusOut() + +end sub + +'------------------------------------------------------------------------- + +sub LoadIncludeFiles + + use "global\system\includes\master.inc" + use "global\system\includes\gvariabl.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + use "global\tools\includes\optional\t_treelist_tools.inc" + use "global\tools\includes\optional\t_control_objects.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_platforms.bas b/testautomation/extensions/optional/e_platforms.bas new file mode 100755 index 000000000000..fa8a348733b7 --- /dev/null +++ b/testautomation/extensions/optional/e_platforms.bas @@ -0,0 +1,58 @@ +'encoding UTF-8 Do not remove or change this line! +'******************************************************************************* +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Supported extension platforms +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\platforms.inc" + + call hStatusIn( "extensions" , "e_platforms.bas" ) + call tExtensionPlatforms() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + + use "global\tools\includes\optional\t_extension_manager_tools.inc" + use "global\tools\includes\optional\t_key_tools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/e_publisher.bas b/testautomation/extensions/optional/e_publisher.bas new file mode 100755 index 000000000000..c1dde48729dc --- /dev/null +++ b/testautomation/extensions/optional/e_publisher.bas @@ -0,0 +1,55 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension publisher string +'* +'\****************************************************************************** + +sub main + + use "extensions\optional\includes\publisher.inc" + + call hStatusIn( "extensions" , "e_publisher.bas" ) + call tExtensionPublisher() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + use "global\tools\includes\optional\t_extension_manager_tools.inc" + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/optional/includes/display_name.inc b/testautomation/extensions/optional/includes/display_name.inc new file mode 100644 index 000000000000..c77fb413e016 --- /dev/null +++ b/testautomation/extensions/optional/includes/display_name.inc @@ -0,0 +1,113 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension display names +'* +'\****************************************************************************** + +testcase tExtensionDisplayName + + if ( gISOLang <> "en-US" ) then + qaerrorlog( "Test is not locale-safe, en-US only" ) + goto endsub + endif + + '///<h1>Extension display names</h1> + '///<u><pre>Synopsis</pre></u>Since CWS jl76 a possibility exists to give an extension a name which + '///+ differs from the filename to be displayed in the extension manager.<br> + '///<u><pre>Specification</pre></u>http://specs.openoffice.org/appwide/packagemanager/packagemanager_gui_spec.sxw<br> + '///<u><pre>Files used</pre></u>gTesttoolPath/extensions/features/input/display_name/*.oxt + + const EXTENSION_COUNT = 5 + + dim cExtensionPath as string + cExtensionPath = gTesttoolPath & "extensions\optional\input\display_name\" + cExtensionPath = convertpath( cExtensionPath ) + + dim cExtensionFileName( EXTENSION_COUNT ) as string + cExtensionFileName( 1 ) = "name1.oxt" + cExtensionFileName( 2 ) = "name2.oxt" + cExtensionFileName( 3 ) = "name3.oxt" + cExtensionFileName( 4 ) = "name4.oxt" + cExtensionFileName( 5 ) = "name5.oxt" + + dim cExtensionDisplayName( EXTENSION_COUNT ) as string + cExtensionDisplayName( 1 ) = "name1 en-US" + cExtensionDisplayName( 2 ) = "name2 en-US-region1" + cExtensionDisplayName( 3 ) = "name3 en" + cExtensionDisplayName( 4 ) = "name4 en-GB" + cExtensionDisplayName( 5 ) = "name5 de" + + dim iCurrentExtension as integer + dim cCurrentExtension as string + dim iStatus as integer + dim bStatus as boolean + + '///<u><pre>Test case specification</u></pre> + '///<ul> + '///+<li>Install test extensions via GUI</li> + for iCurrentExtension = 1 to EXTENSION_COUNT + + cCurrentExtension = cExtensionPath & cExtensionFileName( iCurrentExtension ) + + printlog( "" ) + printlog( "Adding extension by filename: " & cCurrentExtension ) + + iStatus = hExtensionAddGUI( cCurrentExtension , "NoLicense, InstallForUser, NoUpdate, Verbose" ) + if ( iStatus < 1 ) then + warnlog( "Failed to install extension: " & cCurrentExtension ) + endif + + next iCurrentExtension + + '///+<li>Remove all extensions by display name (which also verifies the display name)</li> + bStatus = true + for iCurrentExtension = 1 to EXTENSION_COUNT + + cCurrentExtension = cExtensionDisplayName( iCurrentExtension ) + + printlog( "" ) + printlog( "Removing extension by display name: " & cCurrentExtension ) + + iStatus = hExtensionRemoveGUI( cCurrentExtension ) + if ( iStatus <> 0 ) then + warnlog( "Failed to remove extension: " & cCurrentExtension ) + bStatus = false + endif + + next iCurrentExtension + + '///+<li>If anything went wrong, reset the office/userlayer</li> + if ( not bStatus ) then + call sResetTheOffice + endif + '///</ul> + +endcase + diff --git a/testautomation/extensions/optional/includes/extensions.inc b/testautomation/extensions/optional/includes/extensions.inc new file mode 100644 index 000000000000..8d1c63ea7bab --- /dev/null +++ b/testautomation/extensions/optional/includes/extensions.inc @@ -0,0 +1,676 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/************************************************************************ +'* +'* owner : thorsten.bosbach@sun.com +'* +'* short description : Function test of extension manager +'* +'\************************************************************************ + +testcase tExtensionsFunction + + ' written for CWS jsc7, in master since SRC680m176 + ' additions for CWS sb63 - Dependency checking with versioning - documents 24-30 + ' features: - http://specs.openoffice.org/appwide/packagemanager/simple_extension_license.odt + ' - http://specs.openoffice.org/appwide/packagemanager/extensiondependencies1.odt + '/// The test documents are available at http://qa.openoffice.org/source/browse/qa/qatesttool/framework/basic/input/extensions/ ///' + '/// Textdocuments used in this test and expected messages: ///' + '/// (1/31): simpleLicense\BadDesc.oxt ///' + '/// - BadDesc.oxt/description.xml contains data which cannot be parsed. ///' + '/// - will not install ///' + '/// (2/31): simpleLicense\BadNamespace.oxt ///' + '/// - BadNamespace.oxt/description.xml contains a root element with an unsupported namespace. ///' + '/// - will not install ///' + '/// (3/31): simpleLicense\BadRoot.oxt ///' + '/// - BadRoot.oxt/description.xml does not contain the root element <description>. ///' + '/// - will not install ///' + '/// (4/31): simpleLicense\IncompAttr1.oxt ///' + '/// - ExtensionSoftwareLicenseAgreement dialog exists ///' + '/// - installs and is enabled ///' + '/// (5/31): simpleLicense\IncompAttr2.oxt ///' + '/// - Cannot find a localized license text or a default license text. ///' + '/// - will not install ///' + '/// (6/31): simpleLicense\LongLic.oxt ///' + '/// - ExtensionSoftwareLicenseAgreement dialog exists ///' + '/// - It is a Long License ///' + '/// - installs and is enabled ///' + '/// (7/31): simpleLicense\MissingLic.oxt ///' + '/// - MissingLic.oxt\registration\license_en_US.txt does not exist. ///' + '/// - will not install ///' + '/// (8/31): simpleLicense\MissingLicRef.oxt ///' + '/// - Cannot find a localized license text or a default license text. ///' + '/// - will not install ///' + '/// (9/31): simpleLicense\NoDesc.oxt ///' + '/// - installs and is enabled ///' + '/// (10/31): simpleLicense\NoLangNoDefault.oxt ///' + '/// - Cannot find a localized license text or a default license text. ///' + '/// - will not install ///' + '/// (11/31): simpleLicense\OnlyDefault.oxt ///' + '/// - Cannot find a localized license text or a default license text. ///' + '/// - will not install ///' + '/// (12/31): simpleLicense\ShortLicense.oxt ///' + '/// - ExtensionSoftwareLicenseAgreement dialog exists ///' + '/// - installs and is enabled ///' + '/// (13/31): ///' + '/// - will not install ///' + '/// (14/31): simpleLicense\ShortLicenseShared.oxt ///' + '/// - ExtensionSoftwareLicenseAgreement dialog exists ///' + '/// - installs and is enabled ///' + '/// (15/31): dependencies\broken-dependency.oxt ///' + '/// - broken-dependency.oxt/description.xml contains data which cannot be parsed. ///' + '/// - will not install ///' + '/// (16/31): dependencies\double-dependencies.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/2): Dependency 1 ///' + '/// (2/2): Dependency 2 ///' + '/// - will not install ///' + '/// (17/31): dependencies\empty-dependencies.oxt ///' + '/// - installs and is enabled ///' + '/// (18/31): dependencies\funny-dependency.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): & < > ' " > ' tab . crlf ///' + '/// . em-dash�;. line-separator?. paragraph-separator?. xxxxxxxxxxx... ///' + '/// - will not install ///' + '/// (19/31): dependencies\license-dependency.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Dependency ///' + '/// - will not install ///' + '/// (20/31): dependencies\many-dependencies.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/20): Dependency 1 ///' + '/// (2/20): Dependency 2 ///' + '/// (3/20): Dependency 3 ///' + '/// (4/20): Dependency 4 ///' + '/// (5/20): Dependency 5 ///' + '/// (6/20): Dependency 6 ///' + '/// (7/20): Dependency 7 ///' + '/// (8/20): Dependency 8 ///' + '/// (9/20): Dependency 9 ///' + '/// (10/20): Dependency 10 ///' + '/// (11/20): Dependency 11 ///' + '/// (12/20): Dependency 12 ///' + '/// (13/20): Dependency 13 ///' + '/// (14/20): Dependency 14 ///' + '/// (15/20): Dependency 15 ///' + '/// (16/20): Dependency 16 ///' + '/// (17/20): Dependency 17 ///' + '/// (18/20): Dependency 18 ///' + '/// (19/20): Dependency 19 ///' + '/// (20/20): Dependency 20 ///' + '/// - will not install ///' + '/// (21/31): dependencies\no-dependencies.oxt ///' + '/// - installs and is enabled ///' + '/// (22/31): dependencies\no-description.oxt ///' + '/// - installs and is enabled ///' + '/// (23/31): dependencies\unknown-dependency.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Unknown ///' + '/// - will not install ///' + '/// (24/31): dependencies\version21.oxt ///' + '/// - installs and is enabled ///' + '/// (25/31): dependencies\version10000.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Unknown ///' + '/// - will not install ///' + '/// (26/31): dependencies\version21ns.oxt ///' + '/// - installs and is enabled ///' + '/// (27/31): dependencies\version21other.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Unknown ///' + '/// - will not install ///' + '/// (25/31): dependencies\version25.oxt ///' + '/// - installs and is enabled ///' + '/// (25/31): dependencies\version30.oxt ///' + '/// - installs and is enabled ///' + '/// (25/31): dependencies\version31.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Unknown ///' + '/// - will not install ///' + '/// (27/31): dependencies\version21other.oxt ///' + '/// - UnsatisfiedDependencies dialog exists ///' + '/// (1/1): Unknown ///' + '/// (30/31): dependencies\versionempty.oxt ///' + '/// - installs and is enabled ///' + '/// (31/31): dependencies\versionnone.oxt ///' + '/// - installs and is enabled ///' + '/// (32/41): versions/plain.oxt + '/// - installs and is enabled ///' + '/// (33/41): versions/plain.oxt + '/// - You are about to install version 1.02.4.7.0 of the extension org.openoffice.legacy.plain.oxt. That version is already installed. + '/// - installs and is enabled ///' + '/// (34/41): versions/version_none/plain.oxt + '/// - You are about to install version 0 of the extension org.openoffice.legacy.plain.oxt. The newer version 1.02.4.7.0 is already installed. + '/// - installs and is enabled ///' + '/// (35/41): versions/version_1.2.3/plain.oxt + '/// - You are about to install version 1.2.3 of the extension org.openoffice.legacy.plain.oxt. The older version 0 is already installed. + '/// - installs and is enabled ///' + '/// (36/41): versions/version_1.2.3/plain.oxt + '/// - You are about to install version 1.2.3 of the extension org.openoffice.legacy.plain.oxt. That version is already installed. + '/// - installs and is enabled ///' + '/// (37/41): versions/version_0.0/plain.oxt + '/// - You are about to install version 0.0 of the extension org.openoffice.legacy.plain.oxt. The newer version 1.2.3 is already installed. + '/// - installs and is enabled ///' + '/// (38/41): versions/version_1.2.4.7/plain.oxt + '/// - You are about to install version 1.2.4.7 of the extension org.openoffice.legacy.plain.oxt. The older version 0.0 is already installed. + '/// - installs and is enabled ///' + '/// (39/41): versions/version_1.02.4.7.0/plain.oxt + '/// - You are about to install version 1.02.4.7.0 of the extension org.openoffice.legacy.plain.oxt. That version is already installed. + '/// - installs and is enabled ///' + '/// (40/41): versions/version_1.2.3/plain.oxt + '/// - You are about to install version 1.2.3 of the extension org.openoffice.legacy.plain.oxt. The newer version 1.02.4.7.0 is already installed. + '/// - installs and is enabled ///' + '/// (41/41): versions/version_1.2.15.3/plain.oxt + '/// - You are about to install version 1.2.15.3 of the extension org.openoffice.legacy.plain.oxt. The older version 1.2.3 is already installed. + + dim j,b,i,a,x,y as integer + dim sPath as string + dim aFiles(50) as string + dim aFeatures(50) as string + dim aFileList(50) as string + dim sTemp as string + dim sTemp2 as string + dim sTemp3 as string + dim sTemp4 as string + dim aTemp + dim aTemp2 + dim sFirstStatus as string + dim bFound as boolean + dim aRemovePackages(50) as string + dim bFoundNumber as boolean + dim sLastVersion as string + + sLastVersion = "" + ' want to start and work with just one document window + b = getDocumentCount + hFileCloseAll() + hNewDocument() + + ' load about twenty one extension files, to test the features + ' the list tells the filename and in encoded numbers the features + ' a line looks like: + ' simpleLicense\LongLic.oxt;0,2,1,0 + ' - the filename and the features are seperated by a semicolon + ' - the numbes for the features are seperated by colons + ' 1st number: Unsatisfied dependencies; if there are any, the number counts them; if there are none it is zero and the dialog won't come up + ' 2nd number: License; if there is one the value is 1; it it a long one, where the scroll button needs to be used it is 2; 3 if the license should not be accepted for testing purposes, if there is no license the value is zero + ' 3rd number: If the extension should successfully install the value is one, else zero. + ' 4th number: If an active is expected after selecting a file for installation the value is one, else zero. + ' 5th number: If active is expected the expected version information after selecting a file for installation the value is one, else zero and if an upgrade/downgrade is expected, the number is 2. + + ' Base path for test files + sPath = convertPath(gTestToolPath+"extensions/optional/input/") + ' read filelist and expected features + ListRead(aFileList(), sPath+"files.txt") + a = listCount(aFileList()) + printlog a + for i = 1 to a + aTemp = split (aFileList(i),";") + if uBound(aTemp()) >0 then + listAppend(aFiles(),aTemp(0)) + listAppend(aFeatures(),aTemp(1)) + endif + next i + + ' there are some dependencys to languages... + if iSprache = 49 then + sTemp = aFeatures(4) + aFeatures(4) = aFeatures(5) + aFeatures(5) = sTemp + else + if iSprache <> 01 then + aFeatures(4) = aFeatures(5) + aFeatures(6) = aFeatures(5) + aFeatures(12) = aFeatures(5) + aFeatures(13) = aFeatures(5) + aFeatures(14) = aFeatures(5) + endif + endif + ' cleanup before starting; check that no extension from the list is installed right now; if remove it. + '/// Before starting, look into extension manager, if already a file is installed, that will be used in this test ///' + '/// Remove it. ///' + a = listCount(aFiles()) + dim ii as integer + ToolsPackageManager + kontext "PackageManager" + If PackageManager.exists(10) then + BrowsePackages.typeKeys("<home>") + ii = 1 + while (ii < BrowsePackages.getItemCount+1 ) + kontext "PackageManager" + 'BrowsePackages.typeKeys("+") + 'BrowsePackages.typeKeys("<down>") + BrowsePackages.select ii + sTemp = BrowsePackages.getItemText (ii,1) + if right(sTemp,3) = "oxt" then + for x = 1 to a + sTemp3 = aFiles(x) + aTemp = split(sTemp3,"\") + if uBound(aTemp) < 1 then + aTemp = split(sTemp3,"/") + endif + sTemp3 = aTemp(uBound(aTemp)) + if sTemp = sTemp3 then + qaErrorLog "Package is already installed, trying to remove it: '" + sTemp + "'" + if remove.isEnabled then + remove.click + + kontext "Active" + if ( Active.exists( 2 ) ) then + Active.ok() + else + warnlog( "No confirmation dialog for Extension removal" ) + endif + + Kontext "AddingPackages" + y=0 + while AddingPackages.exists(1) AND (y<30) + printlog "RemovingPackages..." + sleep 1 + y=y+1 + wend + kontext "PackageManager" + BrowsePackages.typeKeys("<up>") + x = 100 + else + warnlog "Package is already installed and can't get removed: '" + sTemp + "'" + ii=ii+1 + x = 101 + endif + endif + next x + if x < 100 then + ii=ii+1 + endif + else + ii=ii+1 + endif + wend + kontext "PackageManager" + PackageManager.close + WaitSlot( 5000 ) + endif + + ' for every test file do... + a = listCount(aFiles()) + for i = 1 to a + printlog "********** Test file ("+i+"/"+a+"): "+aFiles(i) + aTemp = split (aFeatures(i),",") + '/// call Tools - Package/Extension manager ///' + ToolsPackageManager + kontext "PackageManager" + If PackageManager.exists(10) then + '/// going to top of package list and explode every line, until the button 'Add' is enabled ///' + '/// should be 'My Packages' ///' + 'BrowsePackages.typeKeys("<home>") + 'sTemp = BrowsePackages.getSelText + 'sTemp2 = "" + 'while (Not Add.isEnabled AND (sTemp <> sTemp2)) + ' BrowsePackages.typeKeys("+") + ' BrowsePackages.typeKeys("<down>") + ' sTemp2 = sTemp + ' sTemp = BrowsePackages.getSelText + 'wend + 'if sTemp = sTemp2 then + ' warnlog "Couldn't find a way to enable the Add button - aborting" + ' goto endsub + 'endif + 'printlog BrowsePackages.getSelText + '/// click button 'Add' ///' + try + Add.click + catch + warnlog "#i90870# extension manager deadlock/C++ runtimes" + exitrestarttheoffice + ToolsPackageManager + kontext "PackageManager" + Add.click + endcatch + '/// Add Package(s)... dialg comes up ///' + Kontext "OeffnenDlg" + if OeffnenDlg.exists(5) then + '/// put filename into field ///' + Dateiname.setText convertPath(sPath + aFiles(i)) + printlog DateiTyp.getSelText + '/// press button 'Open' ///' + Oeffnen.click + else + warnlog "Add Package(s)... dialog didn't came up" + endif + + 'Asking for whom to install; All: YES, Me: NO, nobody: Cancel + kontext + if active.exists(5) then + sTemp = active.getText + printlog "Messagebox: " + sTemp + ' We only want to handle the installation target here which only + ' pops up if we have the choice (rights to write to shared layer) + if active.getButtonCount = 3 then + try + active.yes + catch + warnlog( "Try...catch: Failed to click Yes-button" ) + endcatch + else + printlog "No installation target message (this is probably a root-installation)" + endif + endif + + '/// Progress dialog comes up ///' + Kontext "AddingPackages" + if AddingPackages.exists(1) then + printlog " - AddingPackages dialog exists" + 'DialogTest(AddingPackages) + endif + + '/// If any error happens, an active comes up, telling what is wrong ///' + ' error is just a dialog with one button + ' version infos have two buttons + Kontext + if active.exists(5) then + sTemp = active.getText + select case active.getbuttoncount + case 1: + y = instr(sTemp, " ") + if cBool(aTemp(3)) then + printlog sTemp + else + warnlog sTemp + endif + case 2: + x = 0 + if cBool(aTemp(4)) then + printlog "Version info message available." + else + warnlog "Version info message available, but not expected" + endif + printlog sTemp + bFoundNumber = false + aTemp2 = split(sTemp," ") + y = uBound(aTemp2) + while ((NOT bFoundNumber) AND (x < y)) + stemp2 = left(aTemp2(x),1) + if isNumeric(stemp2) then + bFoundNumber = TRUE + printlog "Try to install version: " + aTemp2(x) + endif + x=x+1 + wend + if NOT bFoundNumber then + warnlog "No version was mentioned in the version message!" + endif + bFoundNumber = false + while (NOT bFoundNumber AND x < y) + stemp2 = left(aTemp2(x),1) + if isNumeric(stemp2) then + bFoundNumber = TRUE + endif + x=x+1 + wend + if aTemp(4) = "2" AND bFoundNumber then + printlog "Old version is: " + aTemp2(x-1) + elseif bFoundNumber then + warnlog "No old version expected: " + aTemp2(x-1) + elseif aTemp(4) = "2" then + warnlog "Old version expected, but not mentioned." + endif + end select + active.ok + else + if cBool(aTemp(3)) then + if i = 3 then + qaErrorLog "#i73367# " + else + warnlog "errormessage expected, but none came up." + endif + endif + endif + + '/// If there are any unsatisfied dependencies, they are shown now ///' + Kontext "UnsatisfiedDependencies" + if UnsatisfiedDependencies.exists(10) then + if cBool(aTemp(0)) then + printlog " - UnsatisfiedDependencies dialog exists" + else + warnLog "UnsatisfiedDependencies are not expected but available" + endif + DialogTest(UnsatisfiedDependencies) + y = UnsatisfiedDependencyList.getItemCount + if cInt(aTemp(0)) <> y then + warnlog "Difference in dependencies; expected: " + aTemp(0) + "; found: " +y + endif + for x = 1 to y + printlog " ("+x+"/"+y+"): "+UnsatisfiedDependencyList.getItemText(x) + next x + '/// close dialog if available, extension will not be installed ///' + UnsatisfiedDependencies.close + else + if cBool(aTemp(0)) then + warnLog "UnsatisfiedDependencies expected but none shown." + endif + endif + + '/// If there is a license, it is shown now ///' + Kontext "ExtensionSoftwareLicenseAgreement" + if ExtensionSoftwareLicenseAgreement.exists(10) then + if cBool(aTemp(1)) then + printlog " - ExtensionSoftwareLicenseAgreement dialog exists" + else + warnlog "ExtensionSoftwareLicenseAgreement are not expected but shown" + endif + if NOT Accept.isEnabled then + if cInt(aTemp(1)) = 2 then + printlog " Long License" + else + errorlog "Long License" + endif + else + if NOT cInt(aTemp(1)) = 2 then + printlog "Long License" + else + errorlog "Long License" + endif + endif + '/// scroll down until accept button is enabled, click accept button ///' + LicenseText.typeKeys ("<mod1 a>",true) + if Accept.isEnabled then + '/// for testing purposes click cancel one time - the extension should not get installed ///' + if cInt(aTemp(1)) = 3 then + ExtensionSoftwareLicenseAgreement.CANCEL + else + Accept.click + endif + else + qaErrorLog "Accept not enabled.yet" + while NOT Accept.isEnabled + ScrollDown.click + printlog "Scrolling..." + sleep 1 + wend + '/// for testing purposes click cancel one time - the extension should not get installed ///' + if cInt(aTemp(1)) = 3 then + ExtensionSoftwareLicenseAgreement.CANCEL + else + Accept.click + endif + endif + else + if cBool(aTemp(1)) then + errorlog "ExtensionSoftwareLicenseAgreement dialog expected but not shown." + endif + endif + + '/// There may come up another active right now, which would be an error ///' + Kontext + if active.exists(5) then + sTemp = active.getText + if i = 7 then + qaerrorlog "#i67452# " + sTemp + else + if i = 13 then + qaerrorlog "#i73307#" + stemp + else + warnlog sTemp + endif + endif + active.ok + endif + + '/// the progress dialog is now available again ///' + Kontext "AddingPackages" + x=0 + while AddingPackages.exists(1) AND (x<30) + printlog "AddingPackages..." + sleep 1 + x=x+1 + wend + + '/// There may come up another active right now, which would be an error ///' + Kontext + if active.exists(5) then + sTemp = active.getText + warnlog sTemp + active.ok + endif + + ' find out, if the extension got installed + kontext "PackageManager" + BrowsePackages.typeKeys("<home>") + BrowsePackages.typeKeys("+") + y = BrowsePackages.getItemCount + sTemp = aFiles(i) + aTemp2 = split(sTemp,"\") + if uBound(aTemp2) < 1 then + aTemp2 = split(sTemp,"/") + endif + sTemp = aTemp2(uBound(aTemp2)) + printlog stemp + bFound = FALSE + for x = 1 to y + sTemp2 = BrowsePackages.getItemText(x,1) + printlog "("+x+"/"+y+"): "+sTemp2 + ' Mechanism to detect a status change; report it only one time + sTemp3 = BrowsePackages.getItemText(x,3) ' enabled? + sTemp4 = BrowsePackages.getItemText(x,2) ' version + if sTemp3 <> "" AND sFirstStatus = "" then + sFirstStatus = sTemp3 + else + if (sFirstStatus <> sTemp3) AND (sTemp3 <> "") AND (sFirstStatus <> "alreadyshown") then + qaErrorlog "#i67450# " + sFirstStatus + " <> " + sTemp3 + sFirstStatus= "alreadyshown" + endif + endif + if sTemp3 <> "" then + printlog " +++ " + sTemp3 + endif + if sTemp4 <> "" then + sLastVersion = sTemp4 + printlog " Version:" + sTemp4 + endif + if sTemp = sTemp2 then + listAppend(aRemovePackages(), sTemp) + if cBool(aTemp(2)) then + printlog "-------------------------------- Extension got installed" + bFound = TRUE + else + if i = 3 then + qaerrorLog "#i73367# " + else + warnLog "-------------------------------- Extension got installed, but shouldn't do that" + endif + endif + endif + next x + if NOT cBool(aTemp(2)) and bFound then + warnlog "not found" + endif + '/// Close extension manager ///' + PackageManager.OK + 'OK / Close + else + warnlog "Couldn't call Tools -> Package manager - aborting test at " + i + goto endsub + endif + next i + + '/// after installing all extensions, remove them ///' + ' uninstall all components, that were installed + a = listCount(aRemovePackages()) + ToolsPackageManager + kontext "PackageManager" + If PackageManager.exists(10) then + BrowsePackages.typeKeys("<home>") + ii = 1 + while (ii < BrowsePackages.getItemCount +1) + kontext "PackageManager" + 'BrowsePackages.typeKeys("+") + 'BrowsePackages.typeKeys("<down>") + sTemp2 = sTemp + BrowsePackages.select ii + sTemp = BrowsePackages.getItemText (ii,1) + if right(sTemp,3) = "oxt" then + for x = 1 to a + if sTemp = aRemovePackages(x) then + printlog "Package is installed, trying to remove it: '" + sTemp + "'" + if remove.isEnabled then + remove.click + + kontext "Active" + if ( Active.exists( 2 ) ) then + Active.ok() + else + warnlog( "No confirmation for extension removal" ) + endif + + Kontext "AddingPackages" + y=0 + while AddingPackages.exists(1) AND (y<30) + printlog "RemovingPackages..." + sleep 1 + y=y+1 + wend + kontext "PackageManager" + BrowsePackages.typeKeys("<up>") + x = 100 + else + warnlog "Package can't get removed: '" + sTemp + "'" + ii=ii+1 + endif + endif + next x + endif + ii = ii+1 + wend + kontext "PackageManager" + PackageManager.close + else + qaErrorLog "disabling installed extensions failed;" + endif + WaitSlot() + hFileCloseAll() +endcase + + diff --git a/testautomation/extensions/optional/includes/fileopen.inc b/testautomation/extensions/optional/includes/fileopen.inc new file mode 100644 index 000000000000..481cce7d4e14 --- /dev/null +++ b/testautomation/extensions/optional/includes/fileopen.inc @@ -0,0 +1,103 @@ +'encoding UTF-8 Do not remove or change this line! +'******************************************************************************* +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : CWS oxtsysint01 enables installing extensions via file open dialog +'* +'\****************************************************************************** + +testcase tExtensionFileOpen + + printlog( "Install an extension via File Open - new with CWS oxtsysint01" ) + + dim cString as string + + if ( gBuild < 9305 ) then + printlog( "No testing for builds prior to 9305" + goto endsub + endif + + const EXTENSION_NAME = "locationtest.oxt" + dim cPath as string + cPath = gTesttoolPath & "extensions/optional/input/path_to_extension/" & EXTENSION_NAME + + hFileOpen( cPath ) + + kontext "Active" + if ( Active.exists() ) then + printlog( "Extension installation message found, accepting" ) + printlog( Active.getText() ) + Active.ok() + else + warnlog( "Extension installation message missing" ) + endif + + hExtensionRemoveGUI( EXTENSION_NAME ) + + printlog( "Verify that the Add Extension Dialog remembers the last used path..." ) + hExtensionAddGUI( cPath, "" ) + + printlog( "Reopen Extension Manager UI, click Add.. and check the directory" ) + ToolsPackageManager + + kontext "PackageManager" + if ( PackageManager.exists( 3 ) ) then + Add.click() + + Kontext "OeffnenDlg" + if ( OeffnenDlg.exists( 2 ) ) then + + printlog( "Select the last item in the list which should be the extension" ) + DateiAuswahl.select( Dateiauswahl.getItemCount() ) + cString = DateiAuswahl.getSelText() + if ( cString <> EXTENSION_NAME ) then + warnlog( "Incorrect extension listed. Please check path and filename" ) + printlog( "Expected: " & EXTENSION_NAME ) + printlog( "Found...: " & cString ) + printlog( "Issues: #i67122, #i92234" ) + else + printlog( "Found correct extension, the dialog remembers the path" ) + endif + + kontext "OeffnenDlg" + OeffnenDlg.cancel() + else + warnlog( "Could not access Add Extensions Dialog" ) + endif + + kontext "PackageManager" + PackageManager.close() + else + warnlog( "Could not open Extension Manager GUI" ) + endif + + hExtensionRemoveGUI( EXTENSION_NAME ) + +endcase + + diff --git a/testautomation/extensions/optional/includes/help.inc b/testautomation/extensions/optional/includes/help.inc new file mode 100644 index 000000000000..ee313b8d0cc7 --- /dev/null +++ b/testautomation/extensions/optional/includes/help.inc @@ -0,0 +1,213 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extensible help +'* +'\****************************************************************************** + +testcase tExtensibleHelp + + '///<h1>Extensible help</h1> + + '///<u><pre>Synopsis</pre></u>Beginning with CWS ab38 extensions can extend the help application with index entries and content<br> + '///<u><pre>Specification document</pre></u><a href=http://specs.openoffice.org/appwide/help/ExtensibleHelp.odt> + '///+http://specs.openoffice.org/appwide/help/ExtensibleHelp.odt</a><br> + '///<u><pre>Files used:</pre></u>.../extensions/features/input/extensible_help/*.info, *.oxt<br> + '///<u><pre>Test case specification</pre></u> + + ' This is the base path to the input directory where all workfiles are located + dim cExtName as string + dim cExtPath as string + cExtPath = gTesttoolPath & "extensions\optional\input\extensible_help\" + cExtPath = convertpath( cExtPath ) + + ' This is the configuration file for the test extensions. This approach was chosen + ' because the extensions have a lot in common but not enough to make a general + ' routine without any special cases. It is possible to add more extensions easily + ' by just configuring them in the config file. Ideally no canges to the test case + ' itself are required. + const CONFIG_FILE = "extension.info" + dim cCfgPath as string + cCfgPath = cExtPath + cCfgPath = convertpath( cCfgPath & CONFIG_FILE ) + + ' In this array we store the config file. Always make sure it is large enough + ' to hold the entire file + dim cCfgArray( 60 ) as string + + ' Some returnvalues/status variables, general purpose + dim iStatus as integer + dim bStatus as boolean + + ' Control variables for the outer loop (actions for each extension) + dim iCurrentExtension as integer + dim iExtensionCount as integer + + ' Control variables for the inner loop (items to test for an extension) + dim cCurrentHelpItem as string + dim iCurrentHelpItem as integer + dim iHelpItemCount as integer + + ' Values retrieved from the config file or the help content + dim cItem as string + dim cHead as string + dim cLine as string + + ' Correct the position within the index list. If we have a main item with + ' sub-items we might need to move a few entries down in the list to get the + ' sub-items. + dim cMove as string + dim iMove as integer + dim iMoveDown as integer + + do while ( getDocumentCount > 0 ) + call hCloseDocument() + loop + + '///<ul> + '///+<li>Open a writer document (so the help comes up for writer)</li> + gApplication = "WRITER" + call hNewDocument() + if ( getDocumentCount <> 1 ) then + warnlog( "Fatal: Unable to open new writer document" ) + sResetTheOffice + goto endsub + endif + + '///+<li>Read the config file - determine the number of test-extensions</li> + iStatus = hGetDataFileSection( cCfgPath, cCfgArray(), "files", "", "" ) + iExtensionCount = int( hGetValueForKeyAsString( cCfgArray(), "count" ) ) + printlog( "Read configuration for " & iExtensionCount & " files." ) + + '///+<li>Cycle through the configured test-extensions</li> + '///<ul> + for iCurrentExtension = 1 to iExtensionCount + + '///+<li>Read the config file - get settings for current extension</li> + hGetDataFileSection( cCfgPath, cCfgArray(), iCurrentExtension, "", "" ) + cExtPath = cExtPath & hGetValueForKeyAsString( cCfgArray(), "file" ) + cExtName = hGetValueForKeyAsString( cCfgArray(), "name" ) + + + '///+<li>Install the test-extension, cleanup and quit on failure</li> + iStatus = hExtensionAddGUI( cExtPath , "NoUpdate,NoLicense,InstallForUser,Verbose" ) + if ( iStatus < 1 ) then + warnlog( "Fatal: Adding extension failed with rc = " & iStatus ) + sResetTheOffice + goto endsub + endif + + '///+<li>Open the help browser</li> + HelpContents + kontext "StarOfficeHelp" + if ( StarOfficeHelp.exists( 2 ) ) then + + '///+<li>Switch to the index tabpage</li> + TabControl.setPage( IndexPage ) + else + warnlog( "Unable to open help browser" ) + hCloseDocument() + sResetTheOffice() + goto endsub + endif + + '///+<li>Search the help index for the items described in the config file</li> + iHelpItemCount = int( hGetValueForKeyAsString( cCfgArray(), "items" ) ) + printlog( "Testing " & iHelpItemCount & " items" ) + '///<ul> + for iCurrentHelpItem = 1 to iHelpItemCount + + printlog( "" ) + printlog( "Testing item " & iCurrentHelpItem ) + + '///+<li>Get the test strings from the config file</li> + cItem = "hindex_" & iCurrentHelpItem + cMove = "h_move_" & iCurrentHelpItem + cHead = "header_" & iCurrentHelpItem + cItem = hGetValueForKeyAsString( cCfgArray(), cItem ) + cHead = hGetValueForKeyAsString( cCfgArray(), cHead ) + iMove = int( hGetValueForKeyAsString( cCfgArray(), cMove ) + + '///+<li>Enter the search term into the search field of the index page</li> + kontext "StarOfficeHelp" + SearchIndex.setText( cItem ) : WaitSlot() + + for iMoveDown = 1 to iMove + SearchIndex.typeKeys( "<DOWN>" ) + next iMoveDown + + '///+<li>Display the associated help page (content) by clicking on "Display"</li> + DisplayIndex.click() : WaitSlot() + + '///+<li>Get the header from the content</li> + kontext "HelpContent" + HelpContent.typeKeys( "<MOD1 HOME>" ) + HelpContent.typeKeys( "<SHIFT RIGHT>" , len( cHead ) ) + hUseAsyncSlot( "EditCopy" ) + cLine = GetClipBoardText + + '///+<li>Compare the config string with the header</li> + if ( cLine <> cHead ) then + if ( iCurrentHelpItem = 1 and gPlatGroup <> "Win95" ) then + qaerrorlog( "Header is incorrect, slower navigation on Unix(like)" ) + else + warnlog( "Header is incorrect. Please check." ) + endif + printlog( "Found...: " & cLine ) + printlog( "Expected: " & cHead ) + else + printlog( "The header is correct: " & cLine ) + endif + + next iCurrentHelpItem + '///</ul> + + '///+<li>Close the help browser</li> + kontext "StarOfficeHelp" + StarOfficeHelp.typeKeys( "<MOD1 F4>" ) + + '///+<li>Remove the extension</li> + hExtensionRemoveGUI( cExtName ) + + + next iCurrentExtension + '///</ul> + + '///+<li>Close the writer document</li> + call hCloseDocument() + if ( getDocumentCount <> 0 ) then + warnlog( "Fatal: Failed to close writer document" ) + sResetTheOffice + goto endsub + endif + + '///</ul> + +endcase + diff --git a/testautomation/extensions/optional/includes/identifiers.inc b/testautomation/extensions/optional/includes/identifiers.inc new file mode 100644 index 000000000000..377db6e2d89e --- /dev/null +++ b/testautomation/extensions/optional/includes/identifiers.inc @@ -0,0 +1,120 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Use unique identifiers instead of filenames for extensions +'* +'\****************************************************************************** + +testcase tExtensionIdentifiers() + + printlog( "Extension identifiers / reinstallation of extensions" ) + + if ( gBuild <= 9183 ) then + printlog( "Build does not support extension identifiers" ) + goto endsub + endif + + + dim cExtensionPath( 2 ) as string + dim cCommonPath as string + dim cExtensionCount( 3 ) as integer + const EXTENSION_NAME = "identifier.oxt" + dim cExtensionFlags as string + + + ' paths to the extensions - the have identical names but different identifiers + cCommonPath = gTesttoolPath & "extensions\optional\input\identifier\" + cExtensionPath( 1 ) = convertpath( cCommonPath & "legacy\" & EXTENSION_NAME ) + cExtensionPath( 2 ) = convertpath( cCommonPath & "explicit\" & EXTENSION_NAME ) + cExtensionCount( 0 ) = hGetExtensionCount() + + ' Install first extension + cExtensionFlags = "InstallForUser" + cExtensionCount( 1 ) = hExtensionAddGUI( cExtensionPath( 1 ), cExtensionFlags ) + if ( cExtensionCount( 1 ) = cExtensionCount( 0 ) + 1 ) then + printlog( "Extension 1 was installed" ) + else + warnlog( "Incorrect extension count: " & cExtensionCount( 1 ) ) + endif + + ' Install second extension + cExtensionFlags = "InstallForUser" + cExtensionCount( 2 ) = hExtensionAddGUI( cExtensionPath( 2 ), cExtensionFlags ) + if ( cExtensionCount( 2 ) = cExtensionCount( 1 ) + 1 ) then + printlog( "Extension 2 was installed" ) + else + warnlog( "Incorrect extension count: " & cExtensionCount( 2 ) ) + endif + + ' Install first extension again + cExtensionFlags = "InstallForUser,AllowUpdate" + cExtensionCount( 3 ) = hExtensionAddGUI( cExtensionPath( 1 ), cExtensionFlags ) + if ( cExtensionCount( 3 ) = cExtensionCount( 2 ) ) then + printlog( "Extension 1 was installed, overwriting existing" ) + endif + + + ' Install second extension again + cExtensionFlags = "InstallForUser,AllowUpdate" + cExtensionCount( 3 ) = hExtensionAddGUI( cExtensionPath( 2 ), cExtensionFlags ) + if ( cExtensionCount( 3 ) = cExtensionCount( 2 ) ) then + printlog( "Extension 2 was installed, overwriting existing" ) + endif + + hExtensionRemoveGUI( EXTENSION_NAME ) + hExtensionRemoveGUI( EXTENSION_NAME ) + + ' Install first extension + cExtensionFlags = "InstallForUser" + cExtensionCount( 1 ) = hExtensionAddGUI( cExtensionPath( 1 ), cExtensionFlags ) + if ( cExtensionCount( 1 ) = cExtensionCount( 0 ) + 1 ) then + printlog( "Extension 1 was installed again" ) + else + warnlog( "Extension 1 was not installed" ) + endif + + ' Install second extension + cExtensionFlags = "InstallForUser" + cExtensionCount( 2 ) = hExtensionAddGUI( cExtensionPath( 2 ), cExtensionFlags ) + if ( cExtensionCount( 2 ) = cExtensionCount( 1 ) + 1 ) then + printlog( "Extension 2 was installed again" ) + else + warnlog( "Extension 2 was not installed" ) + endif + + hExtensionRemoveGUI( EXTENSION_NAME ) + hExtensionRemoveGUI( EXTENSION_NAME ) + + if ( hGetExtensionCount() <> cExtensionCount( 0 ) ) then + warnlog( "For some reason we have an unexpected number of extensions listed" ) + else + printlog( "Extensions were handled correctly" ) + endif + +endcase diff --git a/testautomation/extensions/optional/includes/location.inc b/testautomation/extensions/optional/includes/location.inc new file mode 100644 index 000000000000..4730f8a7bfec --- /dev/null +++ b/testautomation/extensions/optional/includes/location.inc @@ -0,0 +1,135 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Test the extension locator service +'* +'\****************************************************************************** + +testcase tExtensionLocation + + printlog( "Test the extension locator service" ) + + ' The location of the sample extension and helper document + dim cWorkPath as string + cWorkPath = gTesttoolPath & "extensions\optional\input\path_to_extension\" + cWorkPath = convertpath( cWorkPath ) + + const EXTENSION_NAME = "locationtest.oxt" + const DOCUMENT_NAME = "LocationTest.odt" + const MACRO_NAME = "tExtensionLocation" + + dim brc as boolean + dim irc as integer + dim cMsg as string + + printlog( "Using extension: " & cWorkPath & EXTENSION_NAME ) + printlog( "Using document.: " & cWorkPath & DOCUMENT_NAME ) + + brc = hFileOpen( cWorkPath & DOCUMENT_NAME ) + if ( not brc ) then + brc = hAllowMacroExecution() + if ( not brc ) then + warnlog( "This is not the macro execution warning" ) + endif + else + warnlog( "Macro execution warning is missing" ) + endif + + irc = hMacroOrganizerRunMacro( MACRO_NAME ) + if ( irc = 0 ) then + warnlog( "No macro with the given name could be found, aborting" ) + kontext "Makro" + if ( Makro.exists() ) then + Makro.close() + endif + goto endsub + endif + + kontext "active" + if ( active.exists( 2 ) ) then + cMsg = active.getText() + if ( cMsg <> "" ) then + warnlog( "The messagebox is not empty: " & cMsg ) + else + printlog( "Messagebox is empty, good." ) + endif + active.ok() + else + warnlog( "No messagebox displayed, please check that the macro is executed" ) + endif + + irc = hExtensionAddGUI( cWorkPath & EXTENSION_NAME , "verbose,InstallForUser" ) + irc = hMacroOrganizerRunMacro( MACRO_NAME ) + if ( irc = 0 ) then + warnlog( "No macro with the given name could be found" ) + endif + + kontext "active" + if ( active.exists( 2 ) ) then + cMsg = active.getText() + + if ( cMsg = "" ) then + warnlog( "The messagebox is empty, please check." ) + else + + printlog( "Content of messagebox: " & cMsg ) + + if ( instr( cMsg , "file:///" ) > 0 ) then + printlog( "Found File-URL" ) + else + warnlog( "This does not appear to be a File-URL, please check!" ) + endif + + if ( instr( cMsg , EXTENSION_NAME ) > 0 ) then + printlog( "Extension string is present" ) + else + warnlog( "Extension name seems to be missing" ) + endif + + if ( dir( cMsg ) = "" ) then + warnlog( "The extension could not be found at the expected location" ) + else + printlog( "Extension found. Good." ) + endif + + endif + active.ok() + else + warnlog( "No messagebox displayed, please check that the macro is executed" ) + endif + + irc = hExtensionRemoveGUI( EXTENSION_NAME ) + if ( irc <> 0 ) then + warnlog( "the extension was NOT cleanly removed" ) + endif + + hDestroyDocument() + +endcase + diff --git a/testautomation/extensions/optional/includes/meta-inf.inc b/testautomation/extensions/optional/includes/meta-inf.inc new file mode 100644 index 000000000000..0187e6302c2b --- /dev/null +++ b/testautomation/extensions/optional/includes/meta-inf.inc @@ -0,0 +1,83 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Case sensitive META-INF in packages +'* +'\****************************************************************************** + +testcase tLowerCaseMetaInf + + printlog( "The filename <META-INF> in lowercase letters may prevent installation" ) + + dim cExtensionName as string + cExtensionName = "lowercasemetainf.oxt" + + dim cExtensionPath as string + cExtensionPath = gTesttoolPath & "extensions\optional\input\errors\" + cExtensionPath = cExtensionPath & cExtensionName + + dim irc as integer + + printlog( "Install extension: " & cExtensionPath ) + irc = hExtensionAddGUI( cExtensionPath, "AcceptLicense,InstallForUser" ) + + if ( irc > 0 ) then + + printlog( "Check for unexpected messagebox" ) + kontext "Active" + if ( Active.exists( 3 ) ) then + warnlog( "Extension should install after license has been displayed" ) + printlog( Active.getText() ) + + printlog( "Trying to end test gracefully" ) + Active.ok() + + printlog( "Close Extension Manager" ) + kontext "PackageManager" + if ( PackageManager.exists( 3 ) ) then + PackageManager.close() + else + warnlog( "Cannot access Extension Manager" ) + endif + + else + printlog( "No messagebox, good." ) + endif + + printlog( "Remove extension" ) + hExtensionRemoveGUI( cExtensionName ) + + else + + warnlog( "The extension was not installed" ) + + endif + +endcase + diff --git a/testautomation/extensions/optional/includes/online_update.inc b/testautomation/extensions/optional/includes/online_update.inc new file mode 100644 index 000000000000..c107c1df0f3d --- /dev/null +++ b/testautomation/extensions/optional/includes/online_update.inc @@ -0,0 +1,114 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Hit update button for an extension +'* +'\****************************************************************************** + +testcase tExtensionUpdate + + 'warnlog( "#i81543# Office crashes when Testtool executes .exists() method on some objects" ) + 'goto endsub + + '///<h3>Hit update button for an extension</h3> + '///<ul> + + const EXTENSION_NAME = "ShortLicense.oxt" + + dim cSampleExtension as string + cSampleExtension = gTesttoolPath & "extensions\optional\input\simpleLicense\" + cSampleExtension = cSampleExtension & EXTENSION_NAME + cSampleExtension = convertpath( cSampleExtension ) + + dim iDocumentsBefore as integer + dim iDocumentsAfter as integer + + printlog( "" ) + + if ( dir( cSampleExtension ) <> "" ) then + printlog( "Using extension: " & cSampleExtension ) + else + warnlog( "Fatal: Sample extension could not be found: " & cSampleExtension ) + goto endsub + endif + printlog( "" ) + + + '///+<li>Create a new writer document</li> + hNewDocument() + + '///+<li>get the number of open documents (should be 2)</li> + iDocumentsBefore = getDocumentCount() + + '///+<li>Add sample extension "ShortLicense"</li> + hExtensionAddGUI( cSampleExtension , "InstallForUser,AcceptLicense,Verbose" ) + + '///+<li>Reopen the Extension Manager</li> + printlog( "Reopen Extension Manager" ) + ToolsPackageManager + + '///+<li>Click the "Update"-button</li> + printlog( "Click the update-button" ) + kontext "PackageManager" + updates.click() + + '///+<li>verif y that the update-Dialog is present</li> + kontext "ExtensionUpdate" + if ( ExtensionUpdate.exists() ) then + printlog( "Close update-dialog. Good." ) + ExtensionUpdate.cancel() + else + warnlog( "Extension update dialog is missing" ) + endif + + '///+<li>Close the Extension Manager" + kontext "PackageManager" + if ( PackageManager.exists() ) then + printlog( "Close Extension Manager" ) + PackageManager.close() + endif + + '///+<li>verify that we still have the correct number of documents open</li> + iDocumentsAfter = getDocumentCount() + if ( iDocumentsAfter <> iDocumentsBefore ) then + warnlog( "Incorrect number of documents open. Please verify" ) + else + printlog( "Correct number of documents are open. Good" ) + endif + + '///+<li>Close the second document</li> + hCloseDocument() + + '///+<li>Remove the extension</li> + hExtensionRemoveGUI( EXTENSION_NAME ) + + '///</ul> + +endcase + diff --git a/testautomation/extensions/optional/includes/options.inc b/testautomation/extensions/optional/includes/options.inc new file mode 100644 index 000000000000..43588b748ea0 --- /dev/null +++ b/testautomation/extensions/optional/includes/options.inc @@ -0,0 +1,172 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Options for extensions +'* +'\****************************************************************************** + +testcase tExtensionOptions1 + + '///<h3>Options for extensions</h3> + '///<ul> + + const EXTENSION_NAME = "leaf1.oxt" + const OPTIONS_ITEM = "Writer leaf1 en-US" + const ITEM_POS_1 = 2 + const ITEM_POS_2 = 35 + const ITEM_POS_2_ASIAN = 38 + + dim cExtensionName as string + + dim cExtensionPath as string + cExtensionPath = gTesttoolPath & "extensions\optional\input\options\" + + dim cExtensionFile as string + cExtensionFile = convertpath( cExtensionPath & EXTENSION_NAME ) + + dim irc as integer + dim brc as boolean + + '///+<li>Create one single writer document, the node will be merged into it</li> + do while ( getDocumentCount > 0 ) + hCloseDocument() + loop + gApplication = "WRITER" + hNewDocument() + kontext "DocumentWriter" + DocumentWriter.typeKeys( "tExtensionOptions1" ) + + + '///+<li>Open the Extension Manager, click Add</li> + '///+<li>Load the sample extension "leaf1.oxt"</li> + '///+<li>Close the Extension Manager</li> + printlog( "Add sample extension" ) + hExtensionAddGUI( cExtensionFile, "verbose,InstallForUser" ) + + '///+<li>Reopen the Extension Manager</li> + printlog( "Reopen the Extension Manager" ) + ToolsPackageManager + kontext "PackageManager" + + '///+<li>Select the extension by name</li> + printlog( "Move from the top node to the sample extension" ) + BrowsePackages.select( EXTENSION_NAME ) + + '///+<li>Test some control states for leaf1.oxt node</li> + printlog( "Verify control states" ) + '///<ul> + '///+<li>Add... (enabled)</li> + if ( not Add.isEnabled() ) then + warnlog( "Add button should be enabled" ) + endif + + '///+<li>Remove (enabled)</li> + if ( not Remove.isEnabled() ) then + warnlog( "Remove button should be enabled" ) + endif + + '///+<li>Enable (hidden)</li> + if ( Enable.exists() ) then + warnlog( "Enable button should be hidden" ) + endif + + '///+<li>Disable (enabled)</li> + if ( not Disable.isEnabled() ) then + warnlog( "Disable button should be enabled" ) + endif + + '///+<li>Updates... (enabled)</li> + if ( not Updates.isEnabled() ) then + warnlog( "Updates button should be enabled" ) + endif + + '///+<li>Options... (enabled)</li> + if ( not Options.isEnabled() ) then + warnlog( "Options button should be enabled" ) + endif + '///</ul> + + '///+<li>Click on the Options... button</li> + printlog( "Open Options dialog from Extension Manager" ) + kontext "PackageManager" + if ( options.exists() ) then + options.click() + + '///+<li>Verify that the node "leaf1" is at pos 2 (absolute)</li> + printlog( "Verify presence and position of the leaf node" ) + irc = hSelectOptionsItem( OPTIONS_ITEM , ITEM_POS_1 ) + if ( irc > 0 ) then + warnlog( "Test failed" ) + endif + + '///+<li>Close Options dialog (cancel) + printlog( "Cancel Options dialog to get back to the Extension Manager" ) + OptionenDlg.cancel() + + else + warnlog( "Options button does not exist/implemented in CWS jl61" ) + endif + + '///+<li>Close the Extension Manager</li> + kontext "PackageManager" + printlog( "Close the Extension Manager" ) + PackageManager.close() + + '///+<li>Open Tools/Options</li> + printlog( "From the document open Tools/Options" ) + ToolsOptions + + printlog( "Verify presence and position of the leaf node" ) + if ( bAsianLan ) then + irc = hSelectOptionsItem( OPTIONS_ITEM , ITEM_POS_2_ASIAN ) + else + irc = hSelectOptionsItem( OPTIONS_ITEM , ITEM_POS_2 ) + endif + if ( irc > 1 ) then + warnlog( "Node <" & OPTIONS_ITEM & "> was not found in Tools/Options" ) + else + printlog( "Node is present. Good." ) + endif + + Kontext "OptionenDlg" + printlog( "Cancel Tools/Options to get back to the document" ) + OptionenDlg.cancel() + + '///+<li>Cleanup: Remove the sample extension</li> + printlog( "Remove sample extension" ) + hExtensionRemoveGUI( EXTENSION_NAME ) + + '///+<li>Cleanup: Close document</li> + do while ( getDocumentCount > 0 ) + hCloseDocument() + loop + + '///<ul> +endcase + diff --git a/testautomation/extensions/optional/includes/platforms.inc b/testautomation/extensions/optional/includes/platforms.inc new file mode 100644 index 000000000000..bb8bea80b12f --- /dev/null +++ b/testautomation/extensions/optional/includes/platforms.inc @@ -0,0 +1,126 @@ +'encoding UTF-8 Do not remove or change this line! +'******************************************************************************* +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Supported extension platforms +'* +'\****************************************************************************** + +testcase tExtensionPlatforms + + printlog( "Verify that only extensions designed for this platform are installed" ) + + dim cBasePath as string + cBasePath = gTesttoolPath & "extensions\optional\input\platform\" + cBasePath = convertpath( cBasePath ) + + dim cConfigFile as string + cConfigFile = cBasePath & "extensions.info" + + dim iExtensionCount as integer + dim iCurrentExtension as integer + + dim cCurrentExtensionName as string + dim cCurrentExtensionPath as string + dim cCurrentExtensionFile as string + dim cCurrentExtensionPlatform as string + dim cInfoArray( 200 ) as string + + dim iStatus as integer + dim bShouldInstall as boolean + + hGetDataFileSection( cConfigFile, cInfoArray(), "general", "", "" ) + iExtensionCount = hGetValueForKeyAsInt( cInfoArray(), "ExtensionCount" ) + + for iCurrentExtension = 1 to iExtensionCount + + hGetDataFileSection( cConfigFile, cInfoArray(), iCurrentExtension, "" , "" ) + cCurrentExtensionFile = hGetValueForKeyAsString( cInfoArray(), "File" ) + cCurrentExtensionName = hGetValueForKeyAsString( cInfoArray(), "Name" ) + cCurrentExtensionPath = cBasePath & cCurrentExtensionFile + cCurrentExtensionPlatform = hGetValueForKeyAsString( cInfoArray(), "Platform" ) + + ' Find out whether the extension should install or not + select case ( cCurrentExtensionPlatform ) + case "all" : bShouldInstall = TRUE + case gtSysName : bShouldInstall = TRUE + case gPlatGroup : bShouldInstall = TRUE + case gPlatform : bShouldInstall = TRUE + case else : bShouldInstall = FALSE + end select + + printlog( "" ) + printlog( "Current extension: " & cCurrentExtensionFile ) + iStatus = hExtensionAddGUI( cCurrentExtensionPath, "InstallForUser, NoLicense, NoUpdate, Verbose" ) + + if ( iStatus >= 0 ) then + + kontext "Active" + if ( Active.exists( 2 ) ) then + select case ( bShouldInstall ) + case TRUE : warnlog( "Extension should install but a warning is displayed" ) + case FALSE : printlog( "Extension is for another platform, it is not installed" ) + end select + Active.ok() + else + select case ( bShouldInstall ) + case TRUE : printlog( "No platform mismatch warning. Good." ) + case FALSE : warnlog( "Platform mismatch warning is missing!" ) + end select + endif + + kontext "PackageManager" + if ( PackageManager.exists( 1 ) ) then PackageManager.close() + + iStatus = hExtensionRemoveGUI( cCurrentExtensionName ) + + select case ( iStatus ) + case 0: ' Extension was removed successfully + select case ( bShouldInstall ) + case TRUE : printlog( "Extension was installed and removed, good" ) + case FALSE : warnlog( "The extension was removed but should not be installed" ) + end select + case 3: ' Extension was not found at removal + select case ( bShouldInstall ) + case TRUE : warnlog( "The extension should have been installed but is missing" ) + case FALSE : printlog( "The extension was not installed. Good" ) + end select + case else : ' Any other returnvalue is bad + warnlog( "Unexpected returnvalue from function: " & iStatus ) + end select + + else + warnlog( "Bad status returned, installation of extension failed" ) + goto endsub + endif + + next iCurrentExtension + +endcase + + diff --git a/testautomation/extensions/optional/includes/publisher.inc b/testautomation/extensions/optional/includes/publisher.inc new file mode 100644 index 000000000000..fcf4400ae748 --- /dev/null +++ b/testautomation/extensions/optional/includes/publisher.inc @@ -0,0 +1,285 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension publisher and release notes +'* +'\****************************************************************************** + +testcase tExtensionPublisher + + printlog( "Extension Manager and Release Notes" ) + + if ( gISOLang <> "en-US" ) then + qaerrorlog( "Test does not handle translated strings, aborting" ) + goto endsub + endif + + ' Specification document + ' http://specs.openoffice.org/appwide/packagemanager/online_update_for_extensions.odt + ' http://specs.openoffice.org/appwide/packagemanager/online_update_for_extensions.odt + + ' This is the path where the test-extensions and the info file are located + dim cBasePath as string + cBasePath = gTesttoolPath & "extensions/optional/input/publisher/" + cBasePath = convertpath( cBasePath ) + + ' Modify this file to add test cases or attributes + dim cInfoFile as string : cinfoFile = cBasePath & "extension.info" + + ' The number of files to test. Information about this is stored in the file + ' specified by cInfoFile + dim iFileCount as integer + dim iCurrentFile as integer + dim iExtensionCount as integer + dim iExitCounter as integer + dim iCurrentExtensionCount as integer : iCurrentExtensionCount = 0 + dim iTry as integer + + ' This is the data we get from the configuration file + dim cCurrentFileName as string + dim cHasReleaseNotes as string + dim cReleaseNotes as string + dim cHasPublisher as string + dim cPublisher as string + + ' This is where we store the configuration data. This array must have more + ' lines than cInfoFile contains. + dim cConfigArray( 60 ) as string + + dim cTestString as string + dim bInstallationComplete as boolean : bInstallationComplete = false + + iExtensionCount = hGetExtensionCount() + + + hGetDataFileSection( cInfoFile, cConfigArray(), "info", "", "" ) + iFileCount = int( hGetValueForKeyAsString( cConfigArray() , "filecount" ) ) + printlog( cInfoFile & " specifies " & iFileCount & " documents to load" ) + + iExtensionCount = iExtensionCount + iFileCount + printlog( "Expected number of extensions after installation: " & iExtensionCount ) + + printlog( "Installing extensions" ) + for iCurrentFile = 1 to iFileCount + + hGetDataFileSection( cInfoFile, cConfigArray(), iCurrentFile, "", "" ) + cCurrentFileName = hGetValueForKeyAsString( cConfigArray() , "file" ) + cCurrentFileName = cBasePath & cCurrentFileName + sExtensionCLI( "add" , cCurrentFileName ) + wait 1000 ' This is required, sExtensionCLI is asynchronous. + + next iCurrentFile + printlog( "Finished installing extensions, now verifying..." ) + + hNewDocument() + ToolsPackageManager + + kontext "PackageManager" + if ( PackageManager.exists( 3 ) ) then + + for iTry = 1 to 30 + + iCurrentExtensionCount = BrowsePackages.getItemCount() + + if ( iCurrentExtensionCount = iExtensionCount ) then + printlog( "All extensions have been installed, good." ) + bInstallationComplete = true + exit for + endif + + printlog( "Waiting for listbox: Number of extensions: " & iCurrentExtensionCount ) + + next iTry + + ' If one or more extensions have not been added to the list we better abort the + ' test as the remaining parts need all extensions to be installed causing + ' lots of cryptig errors to appear in the log. + if ( not bInstallationComplete ) then + warnlog( "Not all extensions have been installed. Aborting test." ) + kontext "PackageManager" + if ( PackageManager.exists() ) then + PackageManager.cancel() + PackageManager.notExists( 2 ) + endif + goto endsub + endif + else + warnlog( "The Extension Manager did not open, Aborting test" ) + goto endsub + endif + + + kontext "PackageManager" + printlog( "Going for the update-dialog" ) + if ( Updates.isEnabled() ) then + + printlog( "Updates-button is enabled" ) + Updates.click() + + kontext "ExtensionUpdate" + if ( ExtensionUpdate.exists( 2 ) ) then + + iExitCounter = 0 + do while ( AvailableUpdatesList.getItemCount() < iFileCount ) + printlog( "Waiting for Updates List to populate..." ) + wait( 1000 ) + iExitCounter = iExitCounter + 1 + if ( iExitCounter = 200 ) then + warnlog( "Update list for extensions is stalled (expected: 7), " & _ + "found: " & AvailableUpdatesList.getItemCount() ) + kontext "ExtensionUpdate" + ExtensionUpdate.cancel() + ExtensionUpdate.notExists( 2 ) + kontext "PackageManager" + PackageManager.cancel() + PackageManager.notExists( 2 ) + goto endsub + endif + loop + + if ( ShowAllUpdates.exists() ) then + if ( ShowAllUpdates.isEnabled() ) then + warnlog( """Show all updates"" should be disabled" ) + else + printlog( """Show all updates"" is disabled, good" ) + endif + else + qaerrorlog( """Show all updates"" checkbox could not be accessed" ) + endif + + if ( AvailableUpdatesList.isEnabled() ) then + + printlog( "Available updates list populated in " & iExitCounter & " seconds" ) + + if ( iExitCounter < 20 ) then + + for iCurrentFile = 1 to iFileCount + + hGetDataFileSection( cInfoFile, cConfigArray(), iCurrentFile, "", "" ) + cCurrentFileName = hGetValueForKeyAsString( cConfigArray() , "display_name" ) + + cHasReleaseNotes = hGetValueForKeyAsString( cConfigArray() , "has_release_notes" ) + cReleaseNotes = hGetValueForKeyAsString( cConfigArray() , "release_notes" ) + + cHasPublisher = hGetValueForKeyAsString( cConfigArray() , "has_publisher" ) + cPublisher = hGetValueForKeyAsString( cConfigArray() , "publisher" ) + + AvailableUpdatesList.select( iCurrentFile ) + + if ( AvailableUpdatesList.getText() = cCurrentFileName ) then + printlog( "Testing extension: " & cCurrentFileName ) + + if ( lcase( cHasReleaseNotes ) = "yes" ) then + if ( ReleaseNotesText.isVisible() ) then + printlog( " - Release notes text is visible. Good." ) + qaerrorlog( "#i84700# cannot read static text on extension update dialog" ) + 'cTestString = ReleaseNotesText.getSelText() + 'if ( cTestString = cReleaseNotes ) then + ' printlog( " - Release notes text is ok." ) + 'else + ' warnlog( "Incorrect release notes text" ) + ' printlog( "Expected: " & cReleaseNotes ) + ' printlog( "Found...: " & ctestString ) + 'endif + else + warnlog( "Release notes text is not visible" ) + endif + else + if ( ReleaseNotesText.isVisible() ) then + warnlog( "Release notes should not be visible" ) + else + printlog( " - No release notes for this extension." ) + endif + endif + + if ( lcase( cHasPublisher ) = "yes" ) then + if ( UpdatePublisherText.isVisible() ) then + printlog( " - Publisher text is visible. Good." ) + qaerrorlog( "#i84700# cannot read static text" ) + 'cTestString = UpdatePublisherText.getText() + 'if ( cTestString = cPublisher ) then + ' printlog( " - Release notes text is ok." ) + 'else + ' warnlog( "Incorrect release notes text" ) + ' printlog( "Expected: " & cPublisher ) + ' printlog( "Found...: " & ctestString ) + 'endif + else + warnlog( "Publisher text is not visible." ) + endif + else + if ( UpdatePublisherText.isVisible() ) then + warnlog( "Publisher should not be visible." ) + else + printlog( " - No Publisher for this extension." ) + endif + endif + + else + warnlog( "The extension is not at the expected position" ) + printlog( "Expected: " & cCurrentFileName ) + printlog( "Found...: " & AvailableUpdatesList.getText() ) + exit for + endif + + next iCurrentFile + else + warnlog( "Updates list not fully populated in 15 seconds -> fail" ) + endif + else + warnlog( "No extensions available for update. Installation failed?" ) + endif + + kontext "ExtensionUpdate" + ExtensionUpdate.cancel() + ExtensionUpdate.notExists( 2 ) + else + warnlog( "Extension Update dialog is not open" ) + endif + + else + warnlog( "Update-button on extension manager ui is disabled" ) + endif + + kontext "PackageManager" + PackageManager.close() + PackageManager.notExists( 2 ) + + printlog( "Removing extensions" ) + for iCurrentFile = 1 to iFileCount + hGetDataFileSection( cInfoFile, cConfigArray(), iCurrentFile, "", "" ) + cCurrentFileName = hGetValueForKeyAsString( cConfigArray() , "file" ) + sExtensionCLI( "remove" , cCurrentFileName ) + next iCurrentFile + printlog( "Finished removing extensions" ) + + hFileCloseAll() + +endcase + diff --git a/testautomation/extensions/optional/input/dependencies/broken-dependency.oxt b/testautomation/extensions/optional/input/dependencies/broken-dependency.oxt Binary files differnew file mode 100755 index 000000000000..11bab0a95092 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/broken-dependency.oxt diff --git a/testautomation/extensions/optional/input/dependencies/double-dependencies.oxt b/testautomation/extensions/optional/input/dependencies/double-dependencies.oxt Binary files differnew file mode 100755 index 000000000000..055c27ea53ba --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/double-dependencies.oxt diff --git a/testautomation/extensions/optional/input/dependencies/empty-dependencies.oxt b/testautomation/extensions/optional/input/dependencies/empty-dependencies.oxt Binary files differnew file mode 100755 index 000000000000..ebb18dcbf51b --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/empty-dependencies.oxt diff --git a/testautomation/extensions/optional/input/dependencies/funny-dependency.oxt b/testautomation/extensions/optional/input/dependencies/funny-dependency.oxt Binary files differnew file mode 100755 index 000000000000..9b683e6d1e4b --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/funny-dependency.oxt diff --git a/testautomation/extensions/optional/input/dependencies/license-dependency.oxt b/testautomation/extensions/optional/input/dependencies/license-dependency.oxt Binary files differnew file mode 100755 index 000000000000..b01da4b5ca8a --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/license-dependency.oxt diff --git a/testautomation/extensions/optional/input/dependencies/many-dependencies.oxt b/testautomation/extensions/optional/input/dependencies/many-dependencies.oxt Binary files differnew file mode 100755 index 000000000000..367568143778 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/many-dependencies.oxt diff --git a/testautomation/extensions/optional/input/dependencies/no-dependencies.oxt b/testautomation/extensions/optional/input/dependencies/no-dependencies.oxt Binary files differnew file mode 100755 index 000000000000..6487eb66ae14 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/no-dependencies.oxt diff --git a/testautomation/extensions/optional/input/dependencies/no-description.oxt b/testautomation/extensions/optional/input/dependencies/no-description.oxt Binary files differnew file mode 100755 index 000000000000..1e6579cd7dd4 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/no-description.oxt diff --git a/testautomation/extensions/optional/input/dependencies/unknown-dependency.oxt b/testautomation/extensions/optional/input/dependencies/unknown-dependency.oxt Binary files differnew file mode 100755 index 000000000000..7c2a22c6d5da --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/unknown-dependency.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version10000.oxt b/testautomation/extensions/optional/input/dependencies/version10000.oxt Binary files differnew file mode 100755 index 000000000000..c15b7a117c8c --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version10000.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version21.oxt b/testautomation/extensions/optional/input/dependencies/version21.oxt Binary files differnew file mode 100755 index 000000000000..922b2795555c --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version21.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version21ns.oxt b/testautomation/extensions/optional/input/dependencies/version21ns.oxt Binary files differnew file mode 100755 index 000000000000..5efb2ed90220 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version21ns.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version21other.oxt b/testautomation/extensions/optional/input/dependencies/version21other.oxt Binary files differnew file mode 100755 index 000000000000..d88a8155af65 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version21other.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version25.oxt b/testautomation/extensions/optional/input/dependencies/version25.oxt Binary files differnew file mode 100755 index 000000000000..07c71c3e5983 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version25.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version30.oxt b/testautomation/extensions/optional/input/dependencies/version30.oxt new file mode 100755 index 000000000000..8750e712f8cd --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version30.oxt @@ -0,0 +1,3 @@ +PK@rWn„:_¹t¹¬¢^åÓäc~48 |7ój~ñga³ƒ„utF˜/á‹ž¬›æ@ø×fïó¹ú¯˜'f0Aø³Å{Àn`CÈ϶n_É ê˜›Gù¤ñ%“–s=Ÿ
Ž_¦ŒÈñv¿øxü•Žæ†“F6íÿéèáPü›íN4ç/´ø?ÃÓðžÿ€JCƒFãÆ¿ób¡{àò-þ£ßî+ƒ—÷@¥¹•ñ¹ù)¥9©£ñ?¬âÿ’Д2pý‹ÿLâìðú¨Ô·28µ¨,39Õh4þ‡Sü+Ë·ßÐâß¡ãh¼}䪄ùÄ—%攎äüVÎÀÍÀÇÀ@ømvß2 UÀw€˜\Q³i`6ÜÙ´4¼xÖGͨ(RÁù¹©%™yé )^fÉ)ÅÏ
A~b`’€û‹'¹(5±ÓÜ<eù™)õ<Å%EPÍ@ŽcQzinj^ ˆoÈÀ“œŸ«_\š§_\’X¤Ÿ“˜—®ï™““šž˜SçZ‘œZP’™Ÿq;+3°cÀ„,P>ÈŒ`zåÿî?CÁý1´üß_rm:¼¿†\þŽ–ÿéü—r¬ÿîo£ÅÿLË9«àýñÑòžÖÿie¡Où_-ÿ+¡å%ŽòŸgùoH üç—ÿZ¬±‹@~B)ÿaE>¤æ[Â<Z^Çò¿R…¹<>‡–ÿ/—z,†ß•¢¦Ñò¸”ÿ<6³Àã©hñÿNýG|¼u´üï„ð$)ú”ÿ÷¡åÿ-`ù_¢áå?#JùÏ¿WBk——æåëGx敤¥%&ƒÊÿxY=ŸËÿThdN~Š^*Fó…Ãì#$æ è )ÏÇPÆ®LD0Züà +†6©0 +èZþçGò€çkÐò?׫íùðùœÑüZå¹èUþ[Bó¿ 4ÿ›Àó?<ÿ3€YH¹4Mâ
\ No newline at end of file diff --git a/testautomation/extensions/optional/input/dependencies/version300.oxt b/testautomation/extensions/optional/input/dependencies/version300.oxt Binary files differnew file mode 100644 index 000000000000..39840d84eeb1 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version300.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version301.oxt b/testautomation/extensions/optional/input/dependencies/version301.oxt Binary files differnew file mode 100644 index 000000000000..6dfa188dddf0 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version301.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version31.oxt b/testautomation/extensions/optional/input/dependencies/version31.oxt Binary files differnew file mode 100644 index 000000000000..870b4cc97a9a --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version31.oxt diff --git a/testautomation/extensions/optional/input/dependencies/version937.oxt b/testautomation/extensions/optional/input/dependencies/version937.oxt Binary files differnew file mode 100644 index 000000000000..11dda16cb48c --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/version937.oxt diff --git a/testautomation/extensions/optional/input/dependencies/versionempty.oxt b/testautomation/extensions/optional/input/dependencies/versionempty.oxt Binary files differnew file mode 100755 index 000000000000..a06bb01294f4 --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/versionempty.oxt diff --git a/testautomation/extensions/optional/input/dependencies/versionnone.oxt b/testautomation/extensions/optional/input/dependencies/versionnone.oxt Binary files differnew file mode 100755 index 000000000000..ace2a11651ff --- /dev/null +++ b/testautomation/extensions/optional/input/dependencies/versionnone.oxt diff --git a/testautomation/extensions/optional/input/display_name/name1.oxt b/testautomation/extensions/optional/input/display_name/name1.oxt Binary files differnew file mode 100755 index 000000000000..5a53690d6935 --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/name1.oxt diff --git a/testautomation/extensions/optional/input/display_name/name2.oxt b/testautomation/extensions/optional/input/display_name/name2.oxt Binary files differnew file mode 100755 index 000000000000..f6cbcae3bcbd --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/name2.oxt diff --git a/testautomation/extensions/optional/input/display_name/name3.oxt b/testautomation/extensions/optional/input/display_name/name3.oxt Binary files differnew file mode 100755 index 000000000000..8df750ce62a5 --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/name3.oxt diff --git a/testautomation/extensions/optional/input/display_name/name4.oxt b/testautomation/extensions/optional/input/display_name/name4.oxt Binary files differnew file mode 100755 index 000000000000..6ce4822e3701 --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/name4.oxt diff --git a/testautomation/extensions/optional/input/display_name/name5.oxt b/testautomation/extensions/optional/input/display_name/name5.oxt Binary files differnew file mode 100755 index 000000000000..56973be7817b --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/name5.oxt diff --git a/testautomation/extensions/optional/input/display_name/readme.txt b/testautomation/extensions/optional/input/display_name/readme.txt new file mode 100755 index 000000000000..23173bde63dd --- /dev/null +++ b/testautomation/extensions/optional/input/display_name/readme.txt @@ -0,0 +1,26 @@ +The folder contains extensions which use in the description.xml the following: +-The <display-name> element +The element contains localized child elements. + +To test the display name in the update dialog use the extensions in +desktop/test/deployment/update/simple + + +The following table shows what localized item is used, when the Office the locale +en-US uses. + + +Localization: + +Installed office: en-US + | publisher | release notes +============================================= +name1.oxt | en-US | en-US +--------------------------------------------- +name2.oxt | en-US-region1 | en-US-region1 +--------------------------------------------- +name3.oxt | en | en +--------------------------------------------- +name4.oxt | en-GB | en-GB +--------------------------------------------- +name5.oxt | de | de diff --git a/testautomation/extensions/optional/input/errors/i77436-README.txt b/testautomation/extensions/optional/input/errors/i77436-README.txt new file mode 100755 index 000000000000..d98910a35192 --- /dev/null +++ b/testautomation/extensions/optional/input/errors/i77436-README.txt @@ -0,0 +1,21 @@ +This macro is used to verify the correct handling of the extension. +Install the extension, copy the code to the basic-ide, run it. You should get two messageboxes listing some interfaces. +This macro only works in conjunction with the sample extension in this directory. +Note that the testtool uses the same macro from framework/tools/input/macros.txt otherwise we would have to implement yet +another way of entering macros to the IDE. + + + + +' The sample macro +Sub Main +'test service +o= createUnoService("TestNamesComp") +msgbox o.dbg_supportedInterfaces + +'test singleton +ctx = getDefaultContext +factory = ctx.getValueByName("org.openoffice.test.Names") +msgbox o.dbg_supportedInterfaces + +End Sub diff --git a/testautomation/extensions/optional/input/errors/i77436-extension.oxt b/testautomation/extensions/optional/input/errors/i77436-extension.oxt Binary files differnew file mode 100755 index 000000000000..449014826a64 --- /dev/null +++ b/testautomation/extensions/optional/input/errors/i77436-extension.oxt diff --git a/testautomation/extensions/optional/input/errors/lowercasemetainf.oxt b/testautomation/extensions/optional/input/errors/lowercasemetainf.oxt Binary files differnew file mode 100755 index 000000000000..117f27b3dc5f --- /dev/null +++ b/testautomation/extensions/optional/input/errors/lowercasemetainf.oxt diff --git a/testautomation/extensions/optional/input/eventbinding/DialogComponent.odt b/testautomation/extensions/optional/input/eventbinding/DialogComponent.odt Binary files differnew file mode 100755 index 000000000000..93909c631efa --- /dev/null +++ b/testautomation/extensions/optional/input/eventbinding/DialogComponent.odt diff --git a/testautomation/extensions/optional/input/eventbinding/DialogComponent.oxt b/testautomation/extensions/optional/input/eventbinding/DialogComponent.oxt Binary files differnew file mode 100755 index 000000000000..04d8878c6f45 --- /dev/null +++ b/testautomation/extensions/optional/input/eventbinding/DialogComponent.oxt diff --git a/testautomation/extensions/optional/input/extensible_help/extensible_help_en.oxt b/testautomation/extensions/optional/input/extensible_help/extensible_help_en.oxt Binary files differnew file mode 100755 index 000000000000..c113d59b6187 --- /dev/null +++ b/testautomation/extensions/optional/input/extensible_help/extensible_help_en.oxt diff --git a/testautomation/extensions/optional/input/extensible_help/extensible_help_en_de.oxt b/testautomation/extensions/optional/input/extensible_help/extensible_help_en_de.oxt Binary files differnew file mode 100755 index 000000000000..73d43c2bce6c --- /dev/null +++ b/testautomation/extensions/optional/input/extensible_help/extensible_help_en_de.oxt diff --git a/testautomation/extensions/optional/input/extensible_help/extension.info b/testautomation/extensions/optional/input/extensible_help/extension.info new file mode 100755 index 000000000000..a88f6967d070 --- /dev/null +++ b/testautomation/extensions/optional/input/extensible_help/extension.info @@ -0,0 +1,59 @@ +# This file configures the tExtensionHelp test case found in the files +# extension_help.bas and extension_help.inc. +# It contains information about the extensions and the entries they create +# within the help application +# If you want to add more test files, just increase the "count=" entry and add +# another section to the end of this file. + +# Note that - beginning with CWS jl76 we can have a display name for extensions +# defined in the extension itself to be shown in the extension manager +# The item "name=" was introduced to cope with this. Usually "file=" and "name=" +# are identical + +# The entries to search for in the help index are separated in three parts: +# 1) the help index string (hindex) to be found in the index +# 2) How many items to move down in the index to get the requested subpage +# 3) the header of the content page (header) +# both appended with an underscore and a unique, increasing number. + +[files] +count=1 + +[1] +file=extensible_help_en.oxt +name=extensible_help_en.oxt +items=6 + +hindex_1=ab38 test: All pages +h_move_1=0 +header_1=Extension foo page1 + +hindex_2=ab38 test: All pages +h_move_2=1 +header_2=Extension foo page1 + +hindex_3=ab38 test: All pages +h_move_3=2 +header_3=Extension foo page2 + +hindex_4=subfolder/anotherpage +h_move_4=0 +header_4=Extension foo page2 + +hindex_5=ab38 test: Single level entry page1 +h_move_5=0 +header_5=Extension foo page1 + +hindex_6=ab38 test: Single level entry page1 for swriter and sdraw only +h_move_6=0 +header_6=Extension foo page1 + + +[2] +# This file is currently unconfigured. +file=extensible_help_en_de.oxt +name=extensible_help_en_de.oxt +hindex_1= + + + diff --git a/testautomation/extensions/optional/input/files.txt b/testautomation/extensions/optional/input/files.txt new file mode 100755 index 000000000000..5e37bbd64659 --- /dev/null +++ b/testautomation/extensions/optional/input/files.txt @@ -0,0 +1,45 @@ +simpleLicense\BadDesc.oxt;0,0,0,1,0 +simpleLicense\BadNamespace.oxt;0,0,0,1,0 +simpleLicense\BadRoot.oxt;0,0,0,1,0 +simpleLicense\IncompAttr1.oxt;0,1,1,0,0 +simpleLicense\IncompAttr2.oxt;0,1,1,0,0 +simpleLicense\LongLic.oxt;0,2,1,0,0 +simpleLicense\MissingLic.oxt;0,0,0,1,0 +simpleLicense\MissingLicRef.oxt;0,0,0,1,0 +simpleLicense\NoDesc.oxt;0,0,1,0,0 +simpleLicense\NoLangNoDefault.oxt;0,1,1,0,0 +simpleLicense\OnlyDefault.oxt;0,1,1,0,0 +simpleLicense\ShortLicense.oxt;0,1,1,0,0 +simpleLicense\CancelLicense.oxt;0,3,0,0,0 +simpleLicense\ShortLicenseShared.oxt;0,1,1,0,0 +dependencies\broken-dependency.oxt;0,0,0,1,0 +dependencies\double-dependencies.oxt;2,0,0,0,0 +dependencies\empty-dependencies.oxt;0,0,1,0,0 +dependencies\funny-dependency.oxt;1,0,0,0,0 +dependencies\license-dependency.oxt;1,0,0,0,0 +dependencies\many-dependencies.oxt;20,0,0,0,0 +dependencies\no-dependencies.oxt;0,0,1,0,0 +dependencies\no-description.oxt;0,0,1,0,0 +dependencies\unknown-dependency.oxt;1,0,0,0,0 +dependencies\version21.oxt;0,0,1,0,0 +dependencies\version10000.oxt;1,0,0,0,0 +dependencies\version21ns.oxt;0,0,1,0,0 +dependencies\version21other.oxt;1,0,0,0,0 +dependencies\version25.oxt;0,0,1,0,0 +dependencies\version30.oxt;0,0,1,0,0 +dependencies\version300.oxt;0,0,1,0,0 +dependencies\version301.oxt;0,0,1,0,0 +dependencies\versionempty.oxt;0,0,1,0,0 +dependencies\version31.oxt;1,0,0,0,0 +dependencies\version937.oxt;1,0,0,0,0 +dependencies\versionnone.oxt;0,0,1,0,0 +versions/plain.oxt;0,0,1,0,0 +versions/plain.oxt;0,0,1,0,1 +versions/version_none/plain.oxt;0,0,1,0,2 +versions/version_1.2.3/plain.oxt;0,0,1,0,2 +versions/version_1.2.3/plain.oxt;0,0,1,0,1 +versions/version_0.0/plain.oxt;0,0,1,0,2 +versions/version_1.2.4.7/plain.oxt;0,0,1,0,2 +versions/version_1.02.4.7.0/plain.oxt;0,0,1,0,1 +versions/version_1.2.3/plain.oxt;0,0,1,0,2 +versions/version_1.2.15.3/plain.oxt;0,0,1,0,2 diff --git a/testautomation/extensions/optional/input/identifier/explicit/identifier.oxt b/testautomation/extensions/optional/input/identifier/explicit/identifier.oxt Binary files differnew file mode 100755 index 000000000000..3851e291c970 --- /dev/null +++ b/testautomation/extensions/optional/input/identifier/explicit/identifier.oxt diff --git a/testautomation/extensions/optional/input/identifier/legacy/identifier.oxt b/testautomation/extensions/optional/input/identifier/legacy/identifier.oxt Binary files differnew file mode 100755 index 000000000000..df8bb8449241 --- /dev/null +++ b/testautomation/extensions/optional/input/identifier/legacy/identifier.oxt diff --git a/testautomation/extensions/optional/input/identifier/readme.txt b/testautomation/extensions/optional/input/identifier/readme.txt new file mode 100755 index 000000000000..3588de21feb4 --- /dev/null +++ b/testautomation/extensions/optional/input/identifier/readme.txt @@ -0,0 +1,16 @@ +Extension identifiers + +Extension identifiers have been introduced because of the new filename- +extension (.oxt) might lead to conflicts with older extensions of the same name. +Previously extensions were identified by their filenames only which is +insufficient. Old extensions get an automatic legacy identifier and from now on +an identifier can be explicitly set. + +This directory contains two extensions, one being the legacy and the other one +having the identifier explicitly set. You should be able to install them both +at the same time. + +This feature is tested by framework\basic\f_basic_extension_identifiers.bas. +The spec can be found here: +http://specs.openoffice.org/appwide/packagemanager/extensionidentifiers.odt +The feature was brought in by CWS sb66, the issue is #i69910 diff --git a/testautomation/extensions/optional/input/options/leaf1.oxt b/testautomation/extensions/optional/input/options/leaf1.oxt Binary files differnew file mode 100755 index 000000000000..9c3ff86985b6 --- /dev/null +++ b/testautomation/extensions/optional/input/options/leaf1.oxt diff --git a/testautomation/extensions/optional/input/options/leaf2.oxt b/testautomation/extensions/optional/input/options/leaf2.oxt Binary files differnew file mode 100755 index 000000000000..b95628900c40 --- /dev/null +++ b/testautomation/extensions/optional/input/options/leaf2.oxt diff --git a/testautomation/extensions/optional/input/options/leaves1.oxt b/testautomation/extensions/optional/input/options/leaves1.oxt Binary files differnew file mode 100755 index 000000000000..037389a018b8 --- /dev/null +++ b/testautomation/extensions/optional/input/options/leaves1.oxt diff --git a/testautomation/extensions/optional/input/options/leaves2.oxt b/testautomation/extensions/optional/input/options/leaves2.oxt Binary files differnew file mode 100755 index 000000000000..531b38566352 --- /dev/null +++ b/testautomation/extensions/optional/input/options/leaves2.oxt diff --git a/testautomation/extensions/optional/input/options/leaves3.oxt b/testautomation/extensions/optional/input/options/leaves3.oxt Binary files differnew file mode 100755 index 000000000000..f5bb0f226239 --- /dev/null +++ b/testautomation/extensions/optional/input/options/leaves3.oxt diff --git a/testautomation/extensions/optional/input/options/modules1.oxt b/testautomation/extensions/optional/input/options/modules1.oxt Binary files differnew file mode 100755 index 000000000000..bae652ffbc39 --- /dev/null +++ b/testautomation/extensions/optional/input/options/modules1.oxt diff --git a/testautomation/extensions/optional/input/options/modules2.oxt b/testautomation/extensions/optional/input/options/modules2.oxt Binary files differnew file mode 100755 index 000000000000..d6d7956d459c --- /dev/null +++ b/testautomation/extensions/optional/input/options/modules2.oxt diff --git a/testautomation/extensions/optional/input/options/nodes1.oxt b/testautomation/extensions/optional/input/options/nodes1.oxt Binary files differnew file mode 100755 index 000000000000..b1dfa18d3efa --- /dev/null +++ b/testautomation/extensions/optional/input/options/nodes1.oxt diff --git a/testautomation/extensions/optional/input/options/nodes2.oxt b/testautomation/extensions/optional/input/options/nodes2.oxt Binary files differnew file mode 100755 index 000000000000..a35cfaba9dc8 --- /dev/null +++ b/testautomation/extensions/optional/input/options/nodes2.oxt diff --git a/testautomation/extensions/optional/input/options/nodes3.oxt b/testautomation/extensions/optional/input/options/nodes3.oxt Binary files differnew file mode 100755 index 000000000000..db0bc49da522 --- /dev/null +++ b/testautomation/extensions/optional/input/options/nodes3.oxt diff --git a/testautomation/extensions/optional/input/options/nodes4.oxt b/testautomation/extensions/optional/input/options/nodes4.oxt Binary files differnew file mode 100755 index 000000000000..fe0550fdc655 --- /dev/null +++ b/testautomation/extensions/optional/input/options/nodes4.oxt diff --git a/testautomation/extensions/optional/input/options/nodes5.oxt b/testautomation/extensions/optional/input/options/nodes5.oxt Binary files differnew file mode 100755 index 000000000000..893e9ee3e216 --- /dev/null +++ b/testautomation/extensions/optional/input/options/nodes5.oxt diff --git a/testautomation/extensions/optional/input/options/readme.txt b/testautomation/extensions/optional/input/options/readme.txt new file mode 100755 index 000000000000..da576203972d --- /dev/null +++ b/testautomation/extensions/optional/input/options/readme.txt @@ -0,0 +1,195 @@ +Important: The hander component extensionoptions.jar in the extensions may not +contain exactly the same sources as the one build in the handler directory. To +make sure that debugging works build the handler directory and put the +extensionoptions.jar into the extension. + + + +leaf1.oxt: Defines a leaf under the node WriterNode +================================================================================ + +leaf2.oxt: Defines a leaf under a node that has a name which requires special +"xml encoding". The name is "My Writer's & Settings". The node is not assigned +to a Module and the Node/AllModules property is not true. This is a typical +scenario when a Node had been added to an existing Module and later the Module +was removed. This is a situation which actually should not occur. In this case +DO NOT show the Node in the OOo's options dialog, because it shows only nodes +for a particular module and in this case the Module for the Node is unknown. +In the Extension Manager's +options dialog this Node can be shown because the Module is irrelevant. +See also nodes5.oxt. +================================================================================ + +leaves1.oxt: multiple ordered leaves under available nodes. The leaves Lables are +localized for en-US and de. The following leaves should appear: + +Writer: +-leaves1 Writer 1 en-US +-leaves1 Writer 2 en-US +-leaves1 Writer 3 en-US + +Calc: +-leaves1 Calc 3 en-US +-leaves1 Calc 3 en-US +-leaves1 Calc 3 en-US + +Draw: +-leaves1 Draw 3 en-US +-leaves1 Draw 3 en-US +-leaves1 Draw 3 en-US + +If a german office is used then the strings contain "de" instead of "en-US". +================================================================================ + +leaves2.oxt: Same as leaves1.oxt. Use together with leaves1.oxt to test the +grouping of leaves. +================================================================================ + +leaves3.oxt: Same as leaves1.oxt, but the leaves are not ordered. +================================================================================ + +nodes1.oxt: Defines one node which has AllModules set and which has +no children. Therefore this node should not be displayed. +================================================================================ + +nodes2.oxt: Defines 3 nodes which use AllModules and which form an +ordered group. Every node defines also 3 nodes which have a determined order. + +-nodes2 node 1 en-US + -nodes2 node 1 leaf 1 en-US + -nodes2 node 1 leaf 2 en-US + -nodes2 node 1 leaf 3 en-US + +-nodes2 node 2 en-US + -nodes2 node 2 leaf 1 en-US + -nodes2 node 2 leaf 2 en-US + -nodes2 node 2 leaf 3 en-US + +-nodes2 node 3 en-US + -nodes2 node 3 leaf 1 en-US + -nodes2 node 3 leaf 2 en-US + -nodes2 node 3 leaf 3 en-US + +================================================================================ + +nodes3.oxt: Defines 3 nodes which are placed under different existing Modules. +The nodes and there leaves are ordered. + +Context Writer: +- nodes3 node 1 + nodes3 node 1 leaf 1 en-US + nodes3 node 1 leaf 2 en-US + nodes3 node 1 leaf 3 en-US + +- nodes3 node 2 + nodes3 node 2 leaf 1 en-US + nodes3 node 2 leaf 2 en-US + nodes3 node 2 leaf 3 en-US + +- nodes3 node 3 + nodes3 node 3 leaf 1 en-US + nodes3 node 3 leaf 2 en-US + nodes3 node 3 leaf 3 en-US + +Context Calc: +- nodes3 node 1 + nodes3 node 1 leaf 1 en-US + nodes3 node 1 leaf 2 en-US + nodes3 node 1 leaf 3 en-US + +- nodes3 node 3 + nodes3 node 3 leaf 1 en-US + nodes3 node 3 leaf 2 en-US + nodes3 node 3 leaf 3 en-US + +Context Draw: +- nodes3 node 2 + nodes3 node 2 leaf 1 en-US + nodes3 node 2 leaf 2 en-US + nodes3 node 2 leaf 3 en-US + +================================================================================ + +nodes4.oxt: Same as nodes3.oxt. Use together with nodes3.txt to test the +grouping of nodes. +================================================================================ + +nodes5.oxt: Defines a node which in turn defines 3 leaves. The Node +is not assigned to a Module and the AllModule property is false (which is the +default).This may happen when a node +had been added to an already existing Module and then this Module was removed. For +example, an extension adds a node to the "Writer Module" and the +next office update removes the "Writer Module" (which is rather inconceivable). +Then the node and its leaves MUST NOT be displayed in OOo's options dialog, +because the Module is not known. However, it can be displayed in the +options dialog of the Extension Manager. See also the description for leaf2.oxt. +================================================================================ + +modules1.oxt: Defines two Modules and three Nodes. The Nodes may not +be displayed in OOo's options dialog because there is currently no application +which uses this Module. However the Nodes are displayed in the options dialog +of the Extension Manager. +There are three Nodes defined. The relation ship is this: + +-module1 + -node 1 + -leaf 1 + -leaf 2 + -leaf 3 + -node 2 + -leaf 1 + -leaf 2 + -leaf 3 + -node 3 + -leaf 1 + -leaf 2 + -leaf 3 + +-module2 + -node1 + -leaf 1 + -leaf 2 + -leaf 3 + -node3 + -leaf 1 + -leaf 2 + -leaf 3 + +The options dialog of the Extension Manager shall display only three nodes: + + -node 1 + -leaf 1 + -leaf 2 + -leaf 3 + -node 2 + -leaf 1 + -leaf 2 + -leaf 3 + -node 3 + -leaf 1 + -leaf 2 + -leaf 3 + +or + + -node 1 + -leaf 1 + -leaf 2 + -leaf 3 + -node 3 + -leaf 1 + -leaf 2 + -leaf 3 + -node 2 + -leaf 1 + -leaf 2 + -leaf 3 + +Since the order of Module|s is not defined, the dialog may display first the +Nodes from module2 and then from module1. If a node is already displayed then +it is not shown again. + +================================================================================ + +modules2.oxt: Same as modules1, except that the order of nodes and leaves +is not defined. diff --git a/testautomation/extensions/optional/input/path_to_extension/LocationTest.odt b/testautomation/extensions/optional/input/path_to_extension/LocationTest.odt Binary files differnew file mode 100755 index 000000000000..c28acb26511a --- /dev/null +++ b/testautomation/extensions/optional/input/path_to_extension/LocationTest.odt diff --git a/testautomation/extensions/optional/input/path_to_extension/locationtest.oxt b/testautomation/extensions/optional/input/path_to_extension/locationtest.oxt Binary files differnew file mode 100755 index 000000000000..33ec6af039a0 --- /dev/null +++ b/testautomation/extensions/optional/input/path_to_extension/locationtest.oxt diff --git a/testautomation/extensions/optional/input/platform/all1.oxt b/testautomation/extensions/optional/input/platform/all1.oxt Binary files differnew file mode 100755 index 000000000000..ad9662a7c226 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/all1.oxt diff --git a/testautomation/extensions/optional/input/platform/all2.oxt b/testautomation/extensions/optional/input/platform/all2.oxt Binary files differnew file mode 100755 index 000000000000..632d11b42938 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/all2.oxt diff --git a/testautomation/extensions/optional/input/platform/all3.oxt b/testautomation/extensions/optional/input/platform/all3.oxt Binary files differnew file mode 100755 index 000000000000..ab781552a5aa --- /dev/null +++ b/testautomation/extensions/optional/input/platform/all3.oxt diff --git a/testautomation/extensions/optional/input/platform/extensions.info b/testautomation/extensions/optional/input/platform/extensions.info new file mode 100755 index 000000000000..09424d0db666 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/extensions.info @@ -0,0 +1,146 @@ +# This is a list of extensions with their respective platforms that they run on. +# Note that Platfom=none does not necessarily mean that they do not run at all +# but merely states that this platform is not tested on a regular basis by +# Sun QA. +# Note that we have no means to distinguish between system architectures so +# this test does - for now - exclusively work on i386 based systems (no 64 bit) + +[general] +ExtensionCount=26 + +[1] +File=all1.oxt +Platform=all +Name=All Platforms 1 + +[2] +File=all2.oxt +Platform=all +Name=All Platforms 2 + +[3] +File=all3.oxt +Platform=all +Name=all3.oxt + +[4] +File=freebsd_x86.oxt +Platform=none +Name=Single Platform: freebsd_x86 + +[5] +File=freebsd_x86_64.oxt +Platform=none +Name=Single Platform: freebsd_x86_64 + +[6] +File=invalid1.oxt +Platform=none +Name=Invalid 1 + +[7] +File=invalid2.oxt +Platform=none +Name=Invalid 2 + +[8] +File=invalid3.oxt +Platform=none +Name=Invalid 3 + +[9] +File=linux_arm_eabi.oxt +Platform=none +Name=Single Platform: linux_arm_eabi + +[10] +File=linux_arm_oabi.oxt +Platform=none +Name=Single Platform: linux_arm_oabi + +[11] +File=linux_ia64.oxt +Platform=none +Name=Single Platform: linux_ia64 + +[12] +File=linux_mips_eb.oxt +Platform=none +Name=Single Platform: linux_mips_eb + +[13] +File=linux_mips_el.oxt +Platform=none +Name=Single Platform: linux_mips_el + +[14] +File=linux_powerpc.oxt +Platform=none +Name=Single Platform: linux_powerpc + +[15] +File=linux_powerpc64.oxt +Platform=none +Name=Single Platform: linux_powerpc64 + +[16] +File=linux_s390.oxt +Platform=none +Name=Single Platform: linux_s390 + +[17] +File=linux_s390x.oxt +Platform=none +Name=Single Platform: linux_s390x + +[18] +File=linux_sparc.oxt +Platform=none +Name=Single Platform: linux_sparc + +[19] +File=linux_x86.oxt +Platform=Linux +Name=Single Platform: linux_x86 + +[20] +File=linux_x86_64.oxt +Platform=none +Name=Single Platform: linux_x86_64 + +[21] +File=macosx_powerpc.oxt +Platform=none +Name=Single Platform: macosx_powerpc + +[22] +File=macosx_x86.oxt +Platform=osx +Name=Single Platform: macosx_x86 + +[23] +File=os2_x86.oxt +Platform=eComStation +Name=Single Platform: os2_x86 + +[24] +File=solaris_sparc.oxt +Platform=Solaris Sparc +Name=Single Platform: solaris_sparc + +[25] +File=solaris_x86.oxt +Platform=Solaris x86 +Name=Single Platform: solaris_x86 + +[26] +File=windows_x86.oxt +Platform=w95 +Name=Single Platform: windows_x86 + +#[23] +#File=mul1.oxt +#Platform=all +#Name=Multiple Platforms 1 + + diff --git a/testautomation/extensions/optional/input/platform/freebsd_x86.oxt b/testautomation/extensions/optional/input/platform/freebsd_x86.oxt Binary files differnew file mode 100755 index 000000000000..338f5761deb1 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/freebsd_x86.oxt diff --git a/testautomation/extensions/optional/input/platform/freebsd_x86_64.oxt b/testautomation/extensions/optional/input/platform/freebsd_x86_64.oxt Binary files differnew file mode 100755 index 000000000000..39fee6de1a77 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/freebsd_x86_64.oxt diff --git a/testautomation/extensions/optional/input/platform/invalid1.oxt b/testautomation/extensions/optional/input/platform/invalid1.oxt Binary files differnew file mode 100755 index 000000000000..13d709f438fc --- /dev/null +++ b/testautomation/extensions/optional/input/platform/invalid1.oxt diff --git a/testautomation/extensions/optional/input/platform/invalid2.oxt b/testautomation/extensions/optional/input/platform/invalid2.oxt Binary files differnew file mode 100755 index 000000000000..f14257191b81 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/invalid2.oxt diff --git a/testautomation/extensions/optional/input/platform/invalid3.oxt b/testautomation/extensions/optional/input/platform/invalid3.oxt Binary files differnew file mode 100755 index 000000000000..cadffa4f2ac1 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/invalid3.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_arm_eabi.oxt b/testautomation/extensions/optional/input/platform/linux_arm_eabi.oxt Binary files differnew file mode 100755 index 000000000000..9c504e841b98 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_arm_eabi.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_arm_oabi.oxt b/testautomation/extensions/optional/input/platform/linux_arm_oabi.oxt Binary files differnew file mode 100755 index 000000000000..f2c987f645a7 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_arm_oabi.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_ia64.oxt b/testautomation/extensions/optional/input/platform/linux_ia64.oxt Binary files differnew file mode 100755 index 000000000000..f579a18ab90d --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_ia64.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_mips_eb.oxt b/testautomation/extensions/optional/input/platform/linux_mips_eb.oxt Binary files differnew file mode 100755 index 000000000000..bf0bd942332b --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_mips_eb.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_mips_el.oxt b/testautomation/extensions/optional/input/platform/linux_mips_el.oxt Binary files differnew file mode 100755 index 000000000000..6bd56446831b --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_mips_el.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_powerpc.oxt b/testautomation/extensions/optional/input/platform/linux_powerpc.oxt Binary files differnew file mode 100755 index 000000000000..e301a3fb3ad1 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_powerpc.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_powerpc64.oxt b/testautomation/extensions/optional/input/platform/linux_powerpc64.oxt Binary files differnew file mode 100755 index 000000000000..e5f3ae063923 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_powerpc64.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_s390.oxt b/testautomation/extensions/optional/input/platform/linux_s390.oxt Binary files differnew file mode 100755 index 000000000000..199702ebf056 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_s390.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_s390x.oxt b/testautomation/extensions/optional/input/platform/linux_s390x.oxt Binary files differnew file mode 100755 index 000000000000..2ed250833fb1 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_s390x.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_sparc.oxt b/testautomation/extensions/optional/input/platform/linux_sparc.oxt Binary files differnew file mode 100755 index 000000000000..53dfc71e0c4e --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_sparc.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_x86.oxt b/testautomation/extensions/optional/input/platform/linux_x86.oxt Binary files differnew file mode 100755 index 000000000000..8379539cad34 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_x86.oxt diff --git a/testautomation/extensions/optional/input/platform/linux_x86_64.oxt b/testautomation/extensions/optional/input/platform/linux_x86_64.oxt Binary files differnew file mode 100755 index 000000000000..0fb18227522f --- /dev/null +++ b/testautomation/extensions/optional/input/platform/linux_x86_64.oxt diff --git a/testautomation/extensions/optional/input/platform/macosx_powerpc.oxt b/testautomation/extensions/optional/input/platform/macosx_powerpc.oxt Binary files differnew file mode 100755 index 000000000000..7c146347127a --- /dev/null +++ b/testautomation/extensions/optional/input/platform/macosx_powerpc.oxt diff --git a/testautomation/extensions/optional/input/platform/macosx_x86.oxt b/testautomation/extensions/optional/input/platform/macosx_x86.oxt Binary files differnew file mode 100755 index 000000000000..a20aadfefffd --- /dev/null +++ b/testautomation/extensions/optional/input/platform/macosx_x86.oxt diff --git a/testautomation/extensions/optional/input/platform/mul1.oxt b/testautomation/extensions/optional/input/platform/mul1.oxt Binary files differnew file mode 100755 index 000000000000..b3b555969bdf --- /dev/null +++ b/testautomation/extensions/optional/input/platform/mul1.oxt diff --git a/testautomation/extensions/optional/input/platform/os2_x86.oxt b/testautomation/extensions/optional/input/platform/os2_x86.oxt Binary files differnew file mode 100755 index 000000000000..1c7fd40bef9f --- /dev/null +++ b/testautomation/extensions/optional/input/platform/os2_x86.oxt diff --git a/testautomation/extensions/optional/input/platform/readme.txt b/testautomation/extensions/optional/input/platform/readme.txt new file mode 100755 index 000000000000..2ab102a27d3c --- /dev/null +++ b/testautomation/extensions/optional/input/platform/readme.txt @@ -0,0 +1,49 @@ +Extension which only support one platform +======================================================== + +freebsd_x86.oxt: freebsd_x86 +freebsd_x86_86.oxt: freebsd_x86_64 +linux_arm_eabi.oxt: linux_arm_eabi +linux_arm_oabi.oxt: linux_arm_oabi +linux_ia64.oxt: linux_ia64 +linux_mips_eb.oxt: linux_mips_eb +linux_mips_el.oxt: linux_mips_el +linux_powerpc64.oxt: linux_powerpc64 +linux_powerpc.oxt: linux_powerpc +linux_s390.oxt: linux_s390 +linux_s390x.oxt: linux_s390x +linux_sparc.oxt: linux_sparc +linux_x86.oxt: linux_x86 +linux_x86_64.oxt: linux_x86_64 +macos_powerpc.oxt: macos_powerpc +macos_x86.oxt: macos_x86 +solaris_sparc.oxt: solaris_sparc +solaris_x86.oxt: solaris_x86 +windows_x86.oxt: windows_x86 +os2_x86.oxt: os/2_x86 + +Extensions which support multiple platforms +======================================================= +mul1.oxt: windows_x86, linux_x86, solaris_x86 + + +All platforms +========================================================= +all1.oxt: all, The <platform> element is missing. Default is "all". + +all2.oxt: all, <platform value="all" /> + +all3.oxt: all, no description.xml + + + +Invalid platforms +========================================================= +The following extensions cannot be installed because the platform element +is not correct. We assume that no valid platform is defined. + +invalid1.oxt: <platform /> + +invalid2.oxt: <platform value=""/> + +invalid3.oxt: <platform value="," /> diff --git a/testautomation/extensions/optional/input/platform/solaris_sparc.oxt b/testautomation/extensions/optional/input/platform/solaris_sparc.oxt Binary files differnew file mode 100755 index 000000000000..a61f81f43942 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/solaris_sparc.oxt diff --git a/testautomation/extensions/optional/input/platform/solaris_x86.oxt b/testautomation/extensions/optional/input/platform/solaris_x86.oxt Binary files differnew file mode 100755 index 000000000000..44d43df69184 --- /dev/null +++ b/testautomation/extensions/optional/input/platform/solaris_x86.oxt diff --git a/testautomation/extensions/optional/input/platform/windows_x86.oxt b/testautomation/extensions/optional/input/platform/windows_x86.oxt Binary files differnew file mode 100755 index 000000000000..c66a9b1418fa --- /dev/null +++ b/testautomation/extensions/optional/input/platform/windows_x86.oxt diff --git a/testautomation/extensions/optional/input/publisher/extension.info b/testautomation/extensions/optional/input/publisher/extension.info new file mode 100755 index 000000000000..4750cad09c1f --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/extension.info @@ -0,0 +1,58 @@ +[info] +filecount=7 + +[1] +file=pub1.oxt +display_name=pub1.oxt Version 2.0 +publisher=My OpenOffice en-US +has_publisher=yes +release_notes=Release Notes +has_release_notes=yes + +[2] +file=pub2.oxt +display_name=pub2.oxt Version 2.0 +publisher=My OpenOffice en-US-region1 +has_publisher=yes +release_notes=Release Notes +has_release_notes=yes + +[3] +file=pub3.oxt +display_name=pub3.oxt Version 2.0 +publisher=My OpenOffice en +has_publisher=yes +release_notes=Release Notes +has_release_notes=yes + +[4] +file=pub4.oxt +display_name=pub4.oxt Version 2.0 +publisher=My OpenOffice en-GB +has_publisher=yes +release_notes=Release Notes +has_release_notes=yes + +[5] +file=pub5.oxt +display_name=pub5.oxt Version 2.0 +publisher=My OpenOffice de +has_publisher=yes +release_notes=Release Notes +has_release_notes=yes + +[6] +file=pub6.oxt +display_name=pub6.oxt Version 2.0 +publisher=My OpenOffice en-US +has_publisher=yes +release_notes=Release Notes +has_release_notes=no + +[7] +file=pub7.oxt +display_name=pub7.oxt Version 2.0 +publisher= +has_publisher=no +release_notes=Release Notes +has_release_notes=yes diff --git a/testautomation/extensions/optional/input/publisher/pub1.oxt b/testautomation/extensions/optional/input/publisher/pub1.oxt Binary files differnew file mode 100755 index 000000000000..c44ee9f3bc56 --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub1.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub2.oxt b/testautomation/extensions/optional/input/publisher/pub2.oxt Binary files differnew file mode 100755 index 000000000000..438bcae830a3 --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub2.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub3.oxt b/testautomation/extensions/optional/input/publisher/pub3.oxt Binary files differnew file mode 100755 index 000000000000..62fd69f5595a --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub3.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub4.oxt b/testautomation/extensions/optional/input/publisher/pub4.oxt Binary files differnew file mode 100755 index 000000000000..4f6224f780cd --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub4.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub5.oxt b/testautomation/extensions/optional/input/publisher/pub5.oxt Binary files differnew file mode 100755 index 000000000000..1774e6cd35c3 --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub5.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub6.oxt b/testautomation/extensions/optional/input/publisher/pub6.oxt Binary files differnew file mode 100755 index 000000000000..791a37f8e710 --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub6.oxt diff --git a/testautomation/extensions/optional/input/publisher/pub7.oxt b/testautomation/extensions/optional/input/publisher/pub7.oxt Binary files differnew file mode 100755 index 000000000000..96e96887d0b1 --- /dev/null +++ b/testautomation/extensions/optional/input/publisher/pub7.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/BadDesc.oxt b/testautomation/extensions/optional/input/simpleLicense/BadDesc.oxt Binary files differnew file mode 100755 index 000000000000..436778d54dd4 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/BadDesc.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/BadNamespace.oxt b/testautomation/extensions/optional/input/simpleLicense/BadNamespace.oxt Binary files differnew file mode 100755 index 000000000000..252115348ff6 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/BadNamespace.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/BadRoot.oxt b/testautomation/extensions/optional/input/simpleLicense/BadRoot.oxt Binary files differnew file mode 100755 index 000000000000..1cda25643afb --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/BadRoot.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/CancelLicense.oxt b/testautomation/extensions/optional/input/simpleLicense/CancelLicense.oxt Binary files differnew file mode 100755 index 000000000000..7e1998843254 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/CancelLicense.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/IncompAttr1.oxt b/testautomation/extensions/optional/input/simpleLicense/IncompAttr1.oxt Binary files differnew file mode 100755 index 000000000000..c2cb36b55b1d --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/IncompAttr1.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/IncompAttr2.oxt b/testautomation/extensions/optional/input/simpleLicense/IncompAttr2.oxt Binary files differnew file mode 100755 index 000000000000..fa2235ef7b4c --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/IncompAttr2.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/LongLic.oxt b/testautomation/extensions/optional/input/simpleLicense/LongLic.oxt Binary files differnew file mode 100755 index 000000000000..cb22c91ed576 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/LongLic.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/MissingLic.oxt b/testautomation/extensions/optional/input/simpleLicense/MissingLic.oxt Binary files differnew file mode 100755 index 000000000000..7bfb4b62c551 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/MissingLic.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/MissingLicRef.oxt b/testautomation/extensions/optional/input/simpleLicense/MissingLicRef.oxt Binary files differnew file mode 100755 index 000000000000..a5a0982974ad --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/MissingLicRef.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/NoDesc.oxt b/testautomation/extensions/optional/input/simpleLicense/NoDesc.oxt Binary files differnew file mode 100755 index 000000000000..ac83dac97eba --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/NoDesc.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/NoLangNoDefault.oxt b/testautomation/extensions/optional/input/simpleLicense/NoLangNoDefault.oxt Binary files differnew file mode 100755 index 000000000000..17f125b30f63 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/NoLangNoDefault.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/OnlyDefault.oxt b/testautomation/extensions/optional/input/simpleLicense/OnlyDefault.oxt Binary files differnew file mode 100755 index 000000000000..3b6e4b9fd74a --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/OnlyDefault.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/ShortLicense.oxt b/testautomation/extensions/optional/input/simpleLicense/ShortLicense.oxt Binary files differnew file mode 100755 index 000000000000..7e1998843254 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/ShortLicense.oxt diff --git a/testautomation/extensions/optional/input/simpleLicense/ShortLicenseShared.oxt b/testautomation/extensions/optional/input/simpleLicense/ShortLicenseShared.oxt Binary files differnew file mode 100755 index 000000000000..c0b0950fb133 --- /dev/null +++ b/testautomation/extensions/optional/input/simpleLicense/ShortLicenseShared.oxt diff --git a/testautomation/extensions/optional/input/update/plain1.oxt b/testautomation/extensions/optional/input/update/plain1.oxt Binary files differnew file mode 100755 index 000000000000..ef3edc023c5f --- /dev/null +++ b/testautomation/extensions/optional/input/update/plain1.oxt diff --git a/testautomation/extensions/optional/input/update/plain2.oxt b/testautomation/extensions/optional/input/update/plain2.oxt Binary files differnew file mode 100755 index 000000000000..242ea8bfa6f2 --- /dev/null +++ b/testautomation/extensions/optional/input/update/plain2.oxt diff --git a/testautomation/extensions/optional/input/update/plain3.oxt b/testautomation/extensions/optional/input/update/plain3.oxt Binary files differnew file mode 100755 index 000000000000..7dd56d0314df --- /dev/null +++ b/testautomation/extensions/optional/input/update/plain3.oxt diff --git a/testautomation/extensions/optional/input/update/readme.txt b/testautomation/extensions/optional/input/update/readme.txt new file mode 100755 index 000000000000..e48fa3db5ff3 --- /dev/null +++ b/testautomation/extensions/optional/input/update/readme.txt @@ -0,0 +1,26 @@ +The folder contains only simple extension. That is, they only contain +- META-INF +-t.rdb +-description.xml + +The description.xml contains only a version and one URL to the update data + +For example: + + +<?xml version="1.0" encoding="UTF-8"?> +<description xmlns="http://openoffice.org/extensions/description/2006" + xmlns:xlink="http://www.w3.org/1999/xlink"> + <version value="1.0" /> + + <update-information> + <src xlink:href="http://extensions.openoffice.org/testarea/desktop/simple/plain1.update.xml" /> + </update-information> +</description> + + +The update information which is referenced in the update-information and the update is committed in the extensions/www project. To modify them get the project: + +cvs co extensions/wwww + +the files can be found under extensions/www/testarea/desktop diff --git a/testautomation/extensions/optional/input/versions/plain.oxt b/testautomation/extensions/optional/input/versions/plain.oxt Binary files differnew file mode 100755 index 000000000000..c0cb381edf62 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_0.0/plain.oxt b/testautomation/extensions/optional/input/versions/version_0.0/plain.oxt Binary files differnew file mode 100755 index 000000000000..f156014eb8c3 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_0.0/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_1.02.4.7.0/plain.oxt b/testautomation/extensions/optional/input/versions/version_1.02.4.7.0/plain.oxt Binary files differnew file mode 100755 index 000000000000..521a2b6c77a8 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_1.02.4.7.0/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_1.2.15.3/plain.oxt b/testautomation/extensions/optional/input/versions/version_1.2.15.3/plain.oxt Binary files differnew file mode 100755 index 000000000000..000f3a144fbd --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_1.2.15.3/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_1.2.3/plain.oxt b/testautomation/extensions/optional/input/versions/version_1.2.3/plain.oxt Binary files differnew file mode 100755 index 000000000000..e34264591c58 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_1.2.3/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_1.2.4.7/plain.oxt b/testautomation/extensions/optional/input/versions/version_1.2.4.7/plain.oxt Binary files differnew file mode 100755 index 000000000000..d63c79a734b6 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_1.2.4.7/plain.oxt diff --git a/testautomation/extensions/optional/input/versions/version_none/plain.oxt b/testautomation/extensions/optional/input/versions/version_none/plain.oxt Binary files differnew file mode 100755 index 000000000000..fc227b099ec8 --- /dev/null +++ b/testautomation/extensions/optional/input/versions/version_none/plain.oxt diff --git a/testautomation/extensions/optional/input/web_update/readme.txt b/testautomation/extensions/optional/input/web_update/readme.txt new file mode 100755 index 000000000000..4ae5ddd9182f --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/readme.txt @@ -0,0 +1,133 @@ +The folder contains extensions which need to be updated through a web site. +The "Updates dialog" of the Extension Manager will mark the updates for these +extensions as "browser based update". The Extension Manager will open a browser +for each of the extensions and navigate to the respective website. + +================================================================================ +web1.oxt - web5.oxt: +================================================================================ +They contain <update-information>. That is they reference directly the respective +webX.update.xml (for example, web1.update.xml) files which are available at +http://extensions.openoffice.org/testarea/desktop/website_update/update/... +For example: +http://extensions.openoffice.org/testarea/desktop/website_update/update/web2.update.xml + +The update information contain multiple URLs to "localized" web sites. Each URL is +assigned to a particular local. For example: + +<src xlink:href="http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_de.html" lang="de"/> + +The Extension Manager will choose the URLs where the lang attribute matches most +closely the locale of the office. + +The following table shows what localized web site is used, when the office uses the locale +en-US. The web page will display the locale used. See update/web1_de.html, etc. + + +Localization: + +Installed office en-US + | publisher | release notes +============================================= +web1.oxt | en-US | en-US +--------------------------------------------- +web2.oxt | en-US-region1 | en-US-region1 +--------------------------------------------- +web3.oxt | en | en +--------------------------------------------- +web4.oxt | en-GB | en-GB +--------------------------------------------- +web5.oxt | de | de + + +================================================================================ +web6.oxt +================================================================================ +Need not be committed in extensions/www/testarea/desktop. + +web6.oxt is intended for tests with extensions.services.openoffice.org. +It does not contain <update-information>. That is, the Extension Manager will obtain +the update information from the repository as feed: + +http://updateext.services.openoffice.org/ProductUpdateService/check.Update + +Test +---- +Repository: + +-Create the new extension in the repository. +-Provide a company name and a URL to the company website. In our case this should be + http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html + +-Create a new release for the extension. Upload the description.xml of version 2.0 +(update/web6/description.xml). Provide a download URL for the web site (field + "Download from page / Open follow up page URL", which should be + http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html + Provide release notes. + + +Office: +-Install version 1.0 of the extension: + desktop/test/deployment/update/website_update/web6.oxt + +-Run the update in the Extension Manager + + +Result: +The Update Dialog should show the publisher name as provided in "Provider URL" field +of the extension edit page (not release). + +A release notes link is displayed with an URL to the release notes as provided in +the "Provider Title" field of the extension release edit page. + +When running the update then the web browser should navigate to +http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html + + +================================================================================ +web7.oxt +================================================================================ +Need not be committed in extensions/www/testarea/desktop + +web7.oxt is intended for tests with extensions.services.openoffice.org. +It does not contain <update-information>. That is, the Extension Manager will obtain +the update information from the repository as feed: + +http://updateext.services.openoffice.org/ProductUpdateService/check.Update + +The description.xml which will be uploaded contains URLs for release notes and publisher +names/ URLs. That is, these information are not generated from the information of the +repository web site. + +Test +----------- +Repository: + +-Create the new extension in the repository. +-Provide a company name and a URL to the company website. In our case these should be different + to those provided in the description.xml. These should NOT go into the update feed. + Choose for example as "Provider Title": FOO and as "Provider URL" some valid URL but NOT + http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html + +-Create a new release for the extension. Upload the description.xml of version 2.0 +(update/web7/description.xml). Provide a download URL for the web site (field + "Download from page / Open follow up page URL", which should be + http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html + Provide release notes. + +Office: +-Install version 1.0 of the extension: + desktop/test/deployment/update/website_update/web7.oxt + +-Run the update in the Extension Manager + +Result: +The Update Dialog should show the publisher name as provided in the description.xml. +That is: My OpenOffice en-US and NOT "FOO". + +A release notes link is displayed with an URL to the release notes as provided in +the description.xml. That is: +http://extensions.openoffice.org/testarea/desktop/publisher/release-notes_xxx.html + +When running the update then the web browser should navigate to +http://extensions.openoffice.org/testarea/desktop/website_update/update/web1_en-US.html diff --git a/testautomation/extensions/optional/input/web_update/web1.oxt b/testautomation/extensions/optional/input/web_update/web1.oxt Binary files differnew file mode 100755 index 000000000000..7c17586e0454 --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web1.oxt diff --git a/testautomation/extensions/optional/input/web_update/web2.oxt b/testautomation/extensions/optional/input/web_update/web2.oxt Binary files differnew file mode 100755 index 000000000000..705e70a7533f --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web2.oxt diff --git a/testautomation/extensions/optional/input/web_update/web3.oxt b/testautomation/extensions/optional/input/web_update/web3.oxt Binary files differnew file mode 100755 index 000000000000..4e63a75f0cbf --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web3.oxt diff --git a/testautomation/extensions/optional/input/web_update/web4.oxt b/testautomation/extensions/optional/input/web_update/web4.oxt Binary files differnew file mode 100755 index 000000000000..e66513e68384 --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web4.oxt diff --git a/testautomation/extensions/optional/input/web_update/web5.oxt b/testautomation/extensions/optional/input/web_update/web5.oxt Binary files differnew file mode 100755 index 000000000000..65b02db9347d --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web5.oxt diff --git a/testautomation/extensions/optional/input/web_update/web6.oxt b/testautomation/extensions/optional/input/web_update/web6.oxt Binary files differnew file mode 100755 index 000000000000..98416edfa583 --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web6.oxt diff --git a/testautomation/extensions/optional/input/web_update/web7.oxt b/testautomation/extensions/optional/input/web_update/web7.oxt Binary files differnew file mode 100755 index 000000000000..31ba45f032d5 --- /dev/null +++ b/testautomation/extensions/optional/input/web_update/web7.oxt diff --git a/testautomation/extensions/required/e_update.bas b/testautomation/extensions/required/e_update.bas new file mode 100755 index 000000000000..b5bc2775a646 --- /dev/null +++ b/testautomation/extensions/required/e_update.bas @@ -0,0 +1,58 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension Update Test +'* +'\****************************************************************************** + +sub main + + use "extensions\required\includes\e_update.inc" + + call hStatusIn( "extensions" , "e_update.bas" ) + call tExtensionManagerResources() + call hStatusOut() + +end sub + +'******************************************************************************* + +sub LoadIncludeFiles + + use "global\system\includes\gvariabl.inc" + use "global\system\includes\master.inc" + + use "global\tools\includes\optional\t_user_info.inc" + use "global\tools\includes\optional\t_filetools.inc" + + gApplication = "WRITER" + call GetUseFiles() + +end sub + diff --git a/testautomation/extensions/required/includes/e_update.inc b/testautomation/extensions/required/includes/e_update.inc new file mode 100644 index 000000000000..c3114a65dbbc --- /dev/null +++ b/testautomation/extensions/required/includes/e_update.inc @@ -0,0 +1,287 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension Update Test +'* +'\****************************************************************************** + +testcase tExtensionManagerResources() + + ' Test is based on issue #i86913 and the common rules for update tests (QA) + + ' We need to know if the user may change extension parameters. This is the case + ' when a) the user is root/Administrator or b) the office was installed + ' for the current user only + + dim bUserIsAdmin as boolean : bUserIsAdmin = hCheckForAdministratorPermissions() + dim iBreakCounter as integer : iBreakCounter = 0 + dim iFilterItems as integer + + const MAX_ITERATIONS = 50 + const FILTER_ITEMS = 9 ' This is the number of filters/extension types we know + + printlog( "Ressource test for the Extension Manager UI" ) + ToolsPackageManager + + kontext "PackageManager" + if ( PackageManager.exists( 1 ) ) then + + ' OOo comes with a few preinstalled, shared - extensions. We need at least one. + ' This test is bound to fail if we have a user-installed extension at the + ' first position of the Extension Manager UI list. There is no way we can + ' check that for now. However, this is hardly ever the case. + + if ( BrowsePackages.getItemCount() = 0 ) then + warnlog( "This test requires at least one extension to be installed." ) + printlog( "Some of the controls are not available or disabled." ) + goto endsub + endif + + call dialogtest( PackageManager ) + + kontext "PackgeManager" + printlog( "Add..." ) + Add.click() + + kontext "OeffnenDlg" + if ( OeffnenDlg.exists( 1 ) ) then + iFilterItems = DateiTyp.getItemCount + if ( iFilterItems <> FILTER_ITEMS ) then + warnlog( "The file type filter list is incorrect" ) + printlog( "Expected: " & FILTER_ITEMS ) + printlog( "Found...: " & iFilterItems ) + else + printlog( "The number of filters in Add Extensions Dialog is ok" ) + endif + Oeffnendlg.cancel() + else + warnlog( "File Open dialog did not open" ) + endif + + kontext "PackageManager" + printlog( "Check for updates..." ) + updates.click() + + kontext "ExtensionUpdate" + if ( ExtensionUpdate.exists( 2 ) ) then + call dialogtest( ExtensionUpdate ) + ExtensionUpdate.cancel() + ExtensionUpdate.notExists( 3 ) + else + warnlog( "Extenson Update dialog did not open" ) + endif + + kontext "PackageManager" + printlog( "Controls belonging to extensions" ) + + BrowsePackages.select( 1 ) + printlog( "Extension name.......: " & BrowsePackages.getItemText( 1 , 1 ) ) + printlog( "Extension version....: " & BrowsePackages.getItemText( 1 , 2 ) ) + printlog( "Extension description: " & BrowsePackages.getItemText( 1 , 3 ) ) + + if ( options.exists() ) then + if ( options.isEnabled() ) then + printlog( "Extension has options" ) + options.click() + + kontext "OptionenDlg" + OptionenDLg.close() + WaitSlot() + else + warnlog( "Extension Options button visible but disabled" ) + endif + else + printlog( "Extension Options button does not exist, no options available" ) + endif + + if ( bUserIsAdmin ) then + + ' If the user is Admin or the office was installed in the users + ' home directory we have access to the extensions that reside in + ' the shared layer. This means that the user can remove and disable + ' these extensions. + + kontext "PackageManager" + BrowsePackages.select( 1 ) + if ( disable.exists() ) then + if ( disable.isEnabled() ) then + + disable.click() + + kontext "Active" + if ( Active.exists( 1 ) ) then + printlog( "Disable extension: Warning for other office instance. Good." ) + active.ok() + else + warnlog( "No warning for other office instances running" ) + endif + + ' We now re-enable the extensions. Depending on the "size" + ' of the extension it might take the Extension Manager UI + ' a few seconds to complete the "disable" action. We need to + ' wait for that. + kontext "PackageManager" + BrowsePackages.select( 1 ) + iBreakCounter = 0 + do while( not enable.exists() ) + iBreakCounter = iBreakCounter + 1 + wait( 100 ) + if ( iBreakCounter = MAX_ITERATIONS ) then + warnlog( "Extension not ready within timeframe. Aborting" ) + goto endsub + endif + loop + enable.click() + + kontext "Active" + if ( Active.exists( 1 ) ) then + printlog( "Enable extension: Warning for other office instance. Good." ) + active.ok() + else + warnlog( "No warning for other office instances running" ) + endif + + ' The Extension Manager UI remembers when it has warned about + ' other running instances of the office, so the next time we try + ' to disable/enable the extension there should be no warning. + + kontext "PackageManager" + iBreakCounter = 0 + do while( not disable.exists() ) + iBreakCounter = iBreakCounter + 1 + wait( 100 ) + if ( iBreakCounter = MAX_ITERATIONS ) then + warnlog( "Extension not ready within timeframe. Aborting" ) + goto endsub + endif + loop + disable.click() + + kontext "Active" + if ( Active.exists( 1 ) ) then + warnlog( "There should be no warning when disabling the extension a second time" ) + active.ok() + else + printlog( "Disable extension: No warning for other office instances. Good." ) + endif + + kontext "PackageManager" + iBreakCounter = 0 + do while( not enable.exists() ) + iBreakCounter = iBreakCounter + 1 + wait( 100 ) + if ( iBreakCounter = MAX_ITERATIONS ) then + warnlog( "Extension not ready within timeframe. Aborting" ) + goto endsub + endif + loop + enable.click() + + kontext "Active" + if ( Active.exists( 1 ) ) then + warnlog( "There should be no warning when enabling the extension a second time" ) + active.ok() + else + printlog( "Enable extension: No warning for other office instances. Good." ) + endif + WaitSlot() + + else + warnlog( "User should be able to disable shared extension" ) + endif + else + warnlog( "Cannot disable extension. It might be disabled already or defunct" ) + endif + + kontext "PackageManager" + iBreakCounter = 0 + do while( not remove.isEnabled() ) + iBreakCounter = iBreakCounter + 1 + wait( 100 ) + if ( iBreakCounter = MAX_ITERATIONS ) then + warnlog( "Extension not ready within timeframe. Aborting" ) + goto endsub + endif + loop + + kontext "PackageManager" + if ( remove.isEnabled() ) then + + remove.click() + + ' Note: First time we try to remove an extension we should get a + ' warning that we must make sure that no other office instances + ' are running. If this warning is missing we actually remove the + ' extension which leaves the installation in an inconsistent + ' state. In a "real life" installation this would not work, in a + ' "user space" installation we have to reinstall. Bad that is. + + kontext "Active" + if ( Active.exists( 1 ) ) then + printlog( "Remove extension: Warning for other office instances. Good." ) + active.cancel() + else + warnlog( "No warning for other office instances running" ) + warnlog( "Installation inconsistency: Extension was removed!" ) + endif + WaitSlot() + + ' Note: Like for the disable/enable buttons we should not get + ' a warning for another running office instance when removing + ' an extension for the second time. + + else + warnlog( "User should be able to remove extension" ) + endif + else + + ' if the user does not have Administrator rights he may neither + ' he may neither disable or remove extensions. + + kontext "PackageManager" + if ( disable.isEnabled() ) then + warnlog( "Disable-button enabled for shared extension" ) + endif + + kontext "PackageManager" + if ( remove.isEnabled() ) then + warnlog( "Remove-button enabled for shared extension" ) + endif + endif + + kontext "PackageManager" + PackageManager.close() + + else + warnlog( "Extension Manager UI did not open" ) + endif + +endcase + + diff --git a/testautomation/extensions/required/includes/e_update_oooimprovement.inc b/testautomation/extensions/required/includes/e_update_oooimprovement.inc new file mode 100644 index 000000000000..0981a1836937 --- /dev/null +++ b/testautomation/extensions/required/includes/e_update_oooimprovement.inc @@ -0,0 +1,94 @@ +'encoding UTF-8 Do not remove or change this line! +'************************************************************************** +' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +' +' Copyright 2000, 2010 Oracle and/or its affiliates. +' +' OpenOffice.org - a multi-platform office productivity suite +' +' This file is part of OpenOffice.org. +' +' OpenOffice.org is free software: you can redistribute it and/or modify +' it under the terms of the GNU Lesser General Public License version 3 +' only, as published by the Free Software Foundation. +' +' OpenOffice.org is distributed in the hope that it will be useful, +' but WITHOUT ANY WARRANTY; without even the implied warranty of +' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +' GNU Lesser General Public License version 3 for more details +' (a copy is included in the LICENSE file that accompanied this code). +' +' You should have received a copy of the GNU Lesser General Public License +' version 3 along with OpenOffice.org. If not, see +' <http://www.openoffice.org/license.html> +' for a copy of the LGPLv3 License. +' +'/****************************************************************************** +'* +'* owner : joerg.skottke@sun.com +'* +'* short description : Extension Update Test +'* +'\****************************************************************************** + +testcase tUpdtOOoImprovement + + printlog( "Update test for the tools/options dialog of the OOo Improvement extension" ) + if ( not gExtensionOOoImprovementIsInstalled ) then + qaerrorlog( "The extension is not installed." ) + goto endsub + endif + + dim cLogFile as string + cLogFile = gOfficePath & "user\temp\feedback\Current.csv" + cLogFile = convertpath( cLogFile ) + + if ( hDeleteFile( cLogFile ) ) then + printlog( "Test environment is clean, no logfile present (anymore)" ) + endif + + ToolsOptions + hToolsOptions( "StarOffice", "Improvement" ) + printlog( "Improvement Program tabpage" ) + + call DialogTest( TabOOoImprovement ) + + ParticipateNo.check() + ParticipateYes.check() + + if ( ShowData.isEnabled() ) then + + ShowData.click() + + Kontext "TextImport" + if ( TextImport.exists( 1 ) ) then + printlog( "Text import dialog" ) + + call DialogTest( TextImport ) + TextImport.cancel() + else + warnlog( "#i97340# Show Data button enabled but no logged data found" ) + endif + + Kontext "Active" + if ( Active.exists( 1 ) ) then + printlog( "Messagebox: " & Active.getText() ) + Active.ok() + else + warnlog( "No warning for missing file: " & cLogFile ) + endif + + Kontext "Active" + if ( Active.exists( 1 ) ) then + warnlog( "#97342# Second message for missing " & cLogFile ) + Active.ok() + endif + else + printlog( "Show data is disabled" ) + endif + + Kontext "OptionenDlg" + OptionenDlg.cancel() + +endcase + |