lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] [lmi-commits] master 3c3454d6 5/5: Allow GUI test to fail


From: Vadim Zeitlin
Subject: Re: [lmi] [lmi-commits] master 3c3454d6 5/5: Allow GUI test to fail
Date: Sat, 3 Sep 2022 14:33:50 +0200

On Sat, 3 Sep 2022 00:50:03 +0000 Greg Chicares <gchicares@sbcglobal.net> wrote:

GC> On 9/3/22 00:21, Greg Chicares wrote:
GC> > On 9/2/22 21:20, Vadim Zeitlin wrote:
GC> [...]
GC> >>  $ xvfb-run wine64 /opt/lmi/bin/wx_test.exe --ash_nazg 
--data_path=Z:/opt/lmi/data
GC> [...]
GC> >>  Does the command above also work for you, i.e. is the problem really
GC> >> specific to the nychthemeral script, or does it hang for you too?
GC> > 
GC> > No, it still fails when I copy and paste the command above
GC> > (full copy of terminal session below), and it fails at exactly
GC> > the same point as the nychthemeral test:
GC> > 
GC> >   paste_census: started
GC> >   paste_census: ERROR (Assertion 
'(lmi::ssize(grid_window->GetSelectedRows())) == (1)' failed (
GC> >   expected 1 vs observed 0). [wx_test_paste_census.cpp : 269] )
GC> > 
GC> > after which every subsequent test fails.
GC> 
GC> However, if I run only the last five tests (i.e., those that
GC> follow 'paste_census'), then only one of them fails:
[...]
GC> However, if I change DPI from 192 to 96, then your command
GC> works as intended

 Thanks, I hadn't thought about changing DPI but, unfortunately, everything
still works correctly here even after setting it to 192.

 It should be possible to avoid the assertion failure due to not having any
selection in the grid by just replacing this code:

---------------------------------- >8 --------------------------------------
     // Change class defaults: this requires a selection, so ensure we have one
     // by clicking somewhere inside the control.
     ui.MouseMove
         (grid_window->ClientToScreen
             (wxPoint
                 (10 * grid_window->GetCharWidth()
                 , 3 * grid_window->GetCharHeight()
                 )
             )
         );
     ui.MouseClick();
     wxYield();
---------------------------------- >8 --------------------------------------

with a call to grid_window->SelectRow(0), and it's probably not a huge loss
to not test that clicking in the grid selects a row in it because if this
ever got broken, we'd notice it pretty quickly in interactive use, but I
still don't understand why the code above doesn't work. I also have no idea
why am I not seeing the problem, as I'm using the official lmi build system
in a chroot dedicated to it, and, worse, don't really know how to debug
this further without your help and I'm not sure if it's worth wasting your
time on this.

 Should I just make a properly tested patch with a SelectRow() call?
VZ

Attachment: pgpDuv1XbYWmq.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]