Ignore:
Timestamp:
08/19/10 22:35:39 (3 years ago)
Author:
CrawfordCurrie
Message:

Item9487: changed the Meta object so that only one revision can be loaded into a meta object (though in extremis it can be unloaded again, though that's strongly discouraged). This minimises the risk that the meta object will be reloaded with an unexpected version as a side effect as an operation, such as a macro that employs a rev parameter. Thanks to MichaelDaum for identifying the problem, and pushing me to solve it - it's important that this is fixed before a 1.1 release. Note that this also contributes to resolving an issue I had stacked for 1.2 viz. how to cache and re-use meta objects. THE HIGHEST RISK in this checkin is the change to the Sandbox, which was required to return the stderr output from the co command, which is the only way I can find of determining the latest rev without a second fork to rlog

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/UnitTestContrib/test/unit/StoreTests.pm

    r8248 r8604  
    151151    $meta->remove('TOPICINFO'); 
    152152    $readMeta->remove('TOPICINFO'); 
    153     $meta->{_preferences} = $meta->{_session} = $readMeta->{_session} = undef; 
    154     $meta->{_preferences} = $meta->{_loadedRev} = $readMeta->{_loadedRev} = 
    155       undef; 
     153    foreach my $m ($meta, $readMeta) { 
     154        $m->{_preferences} = $m->{_session} = 
     155          $m->{_latestIsLoaded} = $m->{_loadedRev} = undef; 
     156    } 
    156157    $this->assert_deep_equals( $meta, $readMeta ); 
    157158    my $webObject = Foswiki::Meta->new( $this->{session}, $web ); 
Note: See TracChangeset for help on using the changeset viewer.