Changeset 533


Ignore:
Timestamp:
May 3, 2012, 1:46:16 PM (7 years ago)
Author:
kake
Message:

Fixed SQL for recent changes when metadata_was/metadata_wasnt parameter supplied (fixes #41). Also removed bogus test after checking with bob (who wrote it).

Location:
wiki-toolkit/trunk
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • wiki-toolkit/trunk

    • Property svn:ignore set to
      blib
      lib/Wiki/Toolkit/TestConfig.pm
      MYMETA.json
      MYMETA.yml
      Makefile
      pm_to_blib
      t/plucene
      t/sqlite-test.db
      t/wiki.db
  • wiki-toolkit/trunk/Changes

    r528 r533  
     10.81    ?
     2        Fixed bug with metadata_was in recent changes (#41).
     3
    140.80    5  February 2011
    25        Spelling fix in Wiki::Toolkit::Search::Base
  • wiki-toolkit/trunk/MANIFEST

    r497 r533  
    6565t/060_recent_changes_new_only.t
    6666t/061_list_metadata_by_type.t
     67t/062_recent_changes_metadata_was.t
    6768t/100_formatting.t
    6869t/101_default_formatter.t
  • wiki-toolkit/trunk/lib/Wiki/Toolkit/Store/Database.pm

    r481 r533  
    12691269=item * B<name>: the name of the node
    12701270
    1271 =item * B<version>: the latest version number
    1272 
    1273 =item * B<last_modified>: the timestamp of when it was last modified
     1271=item * B<version>: the version number of the node
     1272
     1273=item * B<last_modified>: timestamp showing when this version was written
    12741274
    12751275=item * B<metadata>: a ref to a hash containing any metadata attached
    1276 to the current version of the node
     1276to this version of the node
    12771277
    12781278=back
     
    14321432    # versions - node or content.
    14331433    my $date_table = "node";
    1434     if ( $include_all_changes || $new_only ) {
     1434    if ( $include_all_changes || $new_only
     1435           || $metadata_was || $metadata_wasnt ) {
    14351436        $date_table = "content";
    14361437        $use_content_table = 1;
  • wiki-toolkit/trunk/t/011_recent_changes.t

    r513 r533  
    205205    is( scalar @nodes, 5,
    206206        "...returned more than once when 'include_all_changes' set" );
    207     @nodes = $wiki->list_recent_changes(
    208         days => 1,
    209         metadata_was => {
    210                             edit_type => "Normal edit",
    211                           },
    212     );
    213     @nodenames = map { $_->{name} } @nodes;
    214     print "# Found nodes: " . join(" ", @nodenames) . "\n";
    215    
    216     TODO: {
    217         local $TODO = 'http://www.wiki-toolkit.org/ticket/41';
    218         is( scalar @nodes, 2,
    219             "metadata_was returns nodes whose current version matches" );
    220     }
    221207}
    222208
Note: See TracChangeset for help on using the changeset viewer.