1 'encoding UTF-8 Do not remove or change this line!
2 '**************************************************************************
3 ' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 ' Copyright 2000, 2010 Oracle and/or its affiliates.
7 ' OpenOffice.org - a multi-platform office productivity suite
9 ' This file is part of OpenOffice.org.
11 ' OpenOffice.org is free software: you can redistribute it and/or modify
12 ' it under the terms of the GNU Lesser General Public License version 3
13 ' only, as published by the Free Software Foundation.
15 ' OpenOffice.org is distributed in the hope that it will be useful,
16 ' but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ' MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ' GNU Lesser General Public License version 3 for more details
19 ' (a copy is included in the LICENSE file that accompanied this code).
21 ' You should have received a copy of the GNU Lesser General Public License
22 ' version 3 along with OpenOffice.org. If not, see
23 ' <http://www.openoffice.org/license.html>
24 ' for a copy of the LGPLv3 License.
26 '/************************************************************************
28 '* owner : gregor.hartmann@oracle.com
30 '* short description :
32 '\******************************************************************************
34 testcase tCompareHelpContent()
36 if ( gIsoLang <> "en-US" ) then
37 printlog( "No testing for languages other than en_US" )
42 ' file related variables
43 dim sFileOut as string
45 dim sFileName as string
46 dim sProductName as string : sProductName = hStringReplaceChar( gProductName, " ", "_" )
48 ' the array that holds the names of the applications
49 dim aTopicsFromUI( 1200 ) as string
51 ' some incremant variables and temporary stuff
52 dim iTopicsFromUI as integer
53 dim iCurrentItem as integer
54 dim sCurrentItem as string
58 ' define input and output paths, presetting variables
60 sFileName = sProductName & "_help_content_" & gIsoLang & ".txt"
61 sFileOut = hGetWorkFile( sFilename )
62 sFileIn = gTesttoolPath & "framework\optional\input\help_browser\"
63 sFileIn = convertpath( sFileIn & sFileName )
65 aTopicsFromUI( 0 ) = "0"
67 ' get the names from the listbox
70 warnlog( "Help not open, aborting test" )
74 hSelectHelpTab( "content" )
76 ' find out, how many items we have in the list
77 iTopicsFromUI = hExpandAllNodes( SearchContent )
78 printlog( "Reading " & iTopicsFromUI & " items from Content Treelist" )
80 ' get all topics from the contents-treelist
81 hGetVisibleNodeNames( SearchContent , aTopicsFromUI() )
85 ' Compare the list against a reference or create a new list, if the
86 ' reference does not exist
88 printlog( "Beginning comparision" )
89 irc = hManageComparisionList( sFileIn, sFileOut, aTopicsFromUI() )
90 hListResultEvaluation( irc , 0 )