More on the menu spec test suite

Jannis Pohlmann jannis at xfce.org
Mon Feb 5 16:18:43 EET 2007


Hey,

I've been playing a lot with the menu spec test suite today.

First of all, here's another bug report (missing result file again):

  !!! Result file (tests/DirectoryDir/result) for tests/DirectoryDir
  missing

I tried to run the submenu-collision test, which failed with the
following (slightly simplified) diff:

--- /tmp/menutestdir/run-result.filtered
+++ /tmp/menutestdir/required-result.sorted
+Applications/
   kate.desktop    /tmp/menutestdir/xdg_data_dir/applications/kate.desktop
+Applications/
   kbabel.desktop /tmp/menutestdir/xdg_data_dir/applications/kbabel.desktop
+Applications/
   KEdit.desktop   /tmp/menutestdir/xdg_data_dir/applications/KEdit.desktop
+Applications/
   kwrite.desktop  /tmp/menutestdir/xdg_data_dir/applications/kwrite.desktop
+Applications/
   quanta.desktop  /tmp/menutestdir/xdg_data_dir/applications/quanta.desktop

The test includes two menus which both have the name "Applications" and
contain an <Include> rule. The test expects no output from the
implementation. If I remember the specification correctly, a new menu
should be created with the two <Include>'s added, which would look like
this:

  <Menu>
    <Name>Applications</Name>
    ...
    <Include>
      <Category>TextEditor</Category>
    </Include>
    <Include>
      <Category>Development</Category>
    </Include>
  </Menu>

The test seems to assume that they are merged this way:
 
  <Menu>
    <Name>Applications</Name>
    <Include>
      <And>
        <Category>TextEditor</Category>
        <Category>Development</Category>
      </And>
    </Include>
  </Menu>

Is this a bug in the test suite or is it just me misunderstanding the
menu specification?

Regards,
  Jannis



More information about the xdg mailing list