That Java a11y/UNO test has been disabled since
commit 553eedabbc
Author: Vladimir Glazounov <vg@openoffice.org>
Date: Tue Oct 23 08:46:59 2007 +0000
INTEGRATION: CWS unoapi1 (1.3.508); FILE MERGED
2007/08/15 13:44:01 cn 1.3.508.1: #i79479# update files
The test can still be seen failing by enabling it locally
like this
diff --git a/dbaccess/qa/unoapi/dbaccess.sce b/dbaccess/qa/unoapi/dbaccess.sce
index 13fa966abe1a..cc67e49a98a9 100644
--- a/dbaccess/qa/unoapi/dbaccess.sce
+++ b/dbaccess/qa/unoapi/dbaccess.sce
@@ -29,4 +29,4 @@
-o dbaccess.OSQLMessageDialog
-o dbaccess.OSingleSelectQueryComposer
#i95611 -o dbaccess.SbaXGridControl
-#i84128 -o dbaccess.TableWindowAccessibility
+-o dbaccess.TableWindowAccessibility
and then running `make JunitTest_dbaccess_unoapi`.
Drop the broken test altogether.
If there should be a relevant test again in the future,
writing a new (presumably C++, see [1]) one from scratch seems more
promising than having to deal with this outdated and disabled
test.
Dropping it also prepares for an upcoming dbaccess a11y change
that would break even more assumptions that the test makes.
[1] https://wiki.documentfoundation.org/Development/Accessibility_Unit_Tests
Change-Id: I540668d84a867e2c051f6c327a0b9c62e594db1b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210358
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
When editing an SQL query in SQL view it is important to keep the
formating. To secure this this fix implements a warning dialogue that
fires in the case a query is last saved in SQL view and the user tries
to open it in Design view and when the user switches from SQL view to
Design view since editing in Design view may canonicalize and rewrite
the query thus destroying its formatting.
This is related to tdf#42713 that impements something similar but for
queries with comments. Note that after this fix the mechanism
implemented for tdf#42713 is only kept for backward compatibility and
could be removed in the future.
Change-Id: I47f46d8953dc4b1e7326413d6f97ca35eeaa3a22
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/208786
Reviewed-by: Vissarion Fisikopoulos <vfisikop@libreoffice.org>
Tested-by: Jenkins
If the query has comments then maintain the format when saving
and warn the user when switching or start editing in design view
that the comments could be lost. The user will have the choice
to keep the formating as well as the placement of comments in
the query.
Change-Id: I3de2313f8808a0b1093ce38de3bc9aa775656067
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/207198
Reviewed-by: Vissarion Fisikopoulos <vfisikop@libreoffice.org>
Tested-by: Jenkins
When an SQL query has comments then those were deleted
when switching to design view. This is fixed and the comments
are maintained. In the case the query is edited in design
view then the comments are inevitably lost.
Change-Id: Ibcf6e36fce88a526c7340d352aca9859b1b3714e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/205441
Tested-by: Jenkins
Reviewed-by: Vissarion Fisikopoulos <vfisikop@libreoffice.org>
Add cases for date, time and timestamp data types in prepared statement
of firebird embedded database. Add unit tests for this particular case
and for testing the DBTypeConversion functions toDate, toTime,
toDateTime that used in the fix.
Change-Id: I91fd2322598b14f84a96f071ed029c9b3e64d51e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/204841
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
The .uno:DBViewTables and .uno:DBViewQueries commands are executed
asynchronously by posting an event to the main thread from
OApplicationController. This creates a race condition for the test where
the following call to .uno:SelectAll silently fails if the event is not
processed before the command is dispatched. After that the attempt to
open a new subcomponent fails, the OnLoad event is never sent and the
test gets stuck in an infinite loop until the kill-wrapper kills it.
This happens for example in the following build log:
https://ci.libreoffice.org/job/gerrit_linux_clang_dbgutil/193243/console
I think I can artificially reproduce the problem locally by adding a
sleep in OApplicationController::OnSelectContainer and at least in that
case this patch appears to fix it. It just makes the tests wait until
the main thread is idle after issuing the commands to switch the view.
Change-Id: If8698114c30cf4219310a9c1b2a2bb365debea8c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194376
Reviewed-by: Neil Roberts <bpeeluk@yahoo.co.uk>
Tested-by: Jenkins
The Base UI tests all need to open a window that operates on the same
database, such as opening the table editor etc. There seems to be a few
race conditions related to opening sub windows that occasionally make
the tests fail so the idea with this patch is to make a central place in
test.py to add code to handle opening the window and closing it when
finished. That way we can add any synchronisation needed in a central
place.
For getting access to the new frame, the three current tests were all
trying to handle this in different ways. insert_relation waits for the
OnSubComponentOpened event, create_join_undo_redo was waiting until the
current focus window changes and the edit_field test was just crossing
its fingers and hoping that the timing worked. This last one is the
likely culprit of the following Jenkins build error for the edit_field
test:
https://ci.libreoffice.org/job/gerrit_linux_clang_dbgutil/193148/
The new helper method always listens for OnSubComponentOpened and then
extracts the new frame from that event.
When closing the window the shared code now always calls
waitUntilAllIdlesDispatched. .uno:CloseWin ends up being executing
asynchronously on the main thread which means that the later call to
.uno:CloseDoc can happen simultaneously. If --oneprocess is not used
then it will even end up directly calling dispose on the main frame
instead of calling CloseDoc. I haven’t been able to replicate the crash
locally, but is seems like this might be related to crashes like the one
below:
https://ci.libreoffice.org/job/gerrit_linux_clang_dbgutil/193204/
Change-Id: Iab0a46c3ca9f8c9eb9ac7f4fecb07f633bd0b312
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194350
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
The existing methods of XUITest to execute a command always use the
active frame to dispatch the command. All of the dbaccess UI tests end
up creating subcomponents (such as the table edit view) and need to send
commands to that. The frames for those are not the “active” frame but
only the “current” frame. All of the tests have ended up making a copy
of a helper function to dispatch to a particular provider. To avoid that
duplication this patch moves it to a common helper directly in XUITest.
This will also make it possible to use the method from test.py in a
later patch.
Note that the order of the arguments has been swapped around to match
that of comphelper::dispatchCommand.
Change-Id: I274fe12e4dfec0bf78359d0e2b70a3cf4db5528c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194348
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
If we don’t close the edit query window then the main database window
closes leaving the just the query window open. When the test is run
without --oneprocess for some reason this causes a crash. This needs
some more investigation but in the meantime this lets us run without
--oneprocess and avoid some issues with the test being flaky on Jenkins
when run alongside the insert_relation test.
Change-Id: Iaca5c0359bf8d29e5ecf317c0689939e92de733a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194292
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
The test creates a database with three tables and then creates a new
query involving all three tables. It does this so it can open the insert
relation dialog with more than two tables. It then selects various
values for the left table and makes sure that the right table is updated
so that it’s not the same.
Change-Id: Ifd23bb3343a415d828697719c17f5afbff55d856
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/194041
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
The UI test opens a database with two tables, creates a join between the
tables and then undos and redos the join.
Change-Id: I4ad03435ce9c6484f54aa563b46d868f21a47209
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/193762
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
I have seen several deadlocks on jenkins in this unit test, normally
with stacks like
privateSnippetExecutor ()
connectivity::hsqldb::OHsqlConnection::flush()
connectivity::hsqldb::ODriverDelegator::flushConnections()
connectivity::hsqldb::OConnectionController::queryTermination
framework::Desktop::impl_sendQueryTerminationEvent
framework::Desktop::terminate()
(anonymous namespace)::Hook::deinitHook((anonymous namespace)::Hook*,
LinkParamNone*)
(anonymous namespace)::Hook::LinkStubdeinitHook(void*, LinkParamNone*)
Link<LinkParamNone*, void>::Call(LinkParamNone*) const
in DeInitVCL()
Implement a proper teardown in the unit test so this does not happen.
Change-Id: I3242752dc38d74128fcd134fe7391f04bd64ebc7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/183391
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Move the tests to SingleSelectQueryComposer_test.cxx
Remove the old SingleSelectQueryComposer JUnit tests/file
Add makefile for SingleSelectQueryComposer_test
Remove the java test from JunitTest_dbaccess_complex.mk
Add the CppUnit test to the Module_dbaccess.mk file to be
run only when Java is enabled on the test machine
Change-Id: I832c80e294be6cd4dced4d358bcee383ea04b0fc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/182759
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
dbaccess/qa/connectivity/tools/CRMDatabase.java - remove unparseable query
dbaccess/qa/unit/dbtest_base.cxx - Add the ODBC escape query
dbacces/qa/unit/CRMDatabase_test.cxx - Add test
The unparseable query has been commented out for a number of
years in the CRMDatabase.java. At some point, this query has become
parseable so this commit removes the old commented out Java query,
moves the it to C++ and adds a CPPUNIT test for the queries parseability.
Change-Id: Ie4d700458bc6dfd52cd87aec75ec202dd12248ef
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/181142
Tested-by: Jenkins
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
I think I managed to disable this when I converted it to
use the shared plugin infrastructure.
So fix that, and then make it much smarter to avoid various
false positives.
Change-Id: I0a4657cff3b40a00434924bf764d024dbfd7d5b3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/176646
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
The problem was, that the function only considered the target XSQLVAR's
sqltype, ignoring sqlsubtype. This led to a situation when assignment
to NUMERIC or DECIMAL was treated as assignment to an underlying type,
like SQL_LONG, performed without taking scale into account.
Use ColumnTypeInfo and its getSdbcType, which provides the correct type,
and add missing cases to setString. Fix setObjectWithInfo to make sure
that the resulting number is correct.
This also fixes export of NUMERIC/DECIMAL in HSQL migration. Previously
it miscalculated the position of decimal separator, which accidentally
went unnoticed in the existing unit test, because it was compensated by
broken handling in Firebird SDBC for the specific numbers in the test.
OResultSet::makeNumericString was also fixed; it didn't handle properly
the case of zero fractional part: initial number 1200 with scale 2 was
converted to a string "12.000" instead of expected "12.00".
Change-Id: I5adac59737d21f91c782fe867d4827fb880fd62a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170812
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
Port the Junit test in DataSource.java over to CppUnit.
In order to port the test as written in Java the
CRM Database was ported, so add a test for that here as
well.
Change-Id: Ib9ac369e3faaa30207b83368889763f0eb063876
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169071
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Otherwise, calling different tests one after the other
will fail with
warn:vcl:994718:994718:vcl/source/app/svmain.cxx:497: DeInitVCL: some top Windows are still alive
text = "lu9947181i0ytl.tmp — LibreOfficeDev Base" type = "10WorkWindow", ptr = 0x555b3ab76810
Change-Id: I6124b768e165ed841738d29c6071e7950b58229f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170058
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
This was added in 0f4451c0b3
"first part of a c++ based test for base" as an example on
how to test base documents.
At this point we already have other base tests doing
more interesting stuff so I believe this test is not needed
anymore
Change-Id: Ice747800f3ab6d887d63595fe9dbdd531acf9014
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168684
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
The old name was misleading (it doesn't take an URL, but a filename);
also, now it's easier to grep for it - doesn't get mixed with
vcl::graphic::loadFromURL.
Change-Id: Ib88d2194200a6a54d2326971e0306ba39f0c7025
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161578
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
OUStringLiteral should be declared constexpr, to enforce
that it is initialised at compile-time and not runtime.
This seems to make a different at least on Visual Studio
Change-Id: I1698f5fa22ddb480347c2f4d444530c2e0e88d92
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153499
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>