+my $file = 'test_file.txt';
+my $content = 'Some file contents.';
+my $upgrade_history = RT->System->UpgradeHistory();
+
+is( keys %$upgrade_history, 0, 'No history in test DB');
+
+RT->System->AddUpgradeHistory(RT =>{
+ action => 'insert',
+ filename => $file,
+ content => $content,
+ stage => 'before',
+ });
+
+$upgrade_history = RT->System->UpgradeHistory();
+ok( exists($upgrade_history->{'RT'}), 'History has an RT key.');
+is( @{$upgrade_history->{'RT'}}, 1, '1 item in history array');
+is($upgrade_history->{RT}[0]{stage}, 'before', 'stage is before for item 1');