GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

Verified Commit 4261c714 authored by boklm's avatar boklm

Bug 25101: Generate incremental mars for nightly builds

parent 679ee355
......@@ -3,9 +3,11 @@ package TBBTestSuite::TestSuite::TorBrowserBuild;
use strict;
use parent 'TBBTestSuite::TestSuite::RBMBuild';
use TBBTestSuite::Common qw(run_to_file);
use TBBTestSuite::GitRepo;
use File::Copy;
use IO::CaptureOutput qw(capture_exec);
use Path::Tiny;
sub description {
'Tor Browser Build';
......@@ -15,6 +17,13 @@ sub type {
'tor-browser_build';
};
sub test_types {
my $self = shift;
my $res = $self->SUPER::test_types();
$res->{make_incrementals} = \&make_incrementals;
return $res;
}
sub set_tests {
my ($testsuite) = @_;
$testsuite->{tests} = [
......@@ -31,6 +40,12 @@ sub set_tests {
],
publish_dir => 'nightly-linux-x86_64',
},
{
name => 'incrementals-nightly-linux-x86_64',
descr => 'create incrementals for tor-browser nightly linux-x86_64',
type => 'make_incrementals',
publish_dir => 'nightly-linux-x86_64',
},
{
name => 'nightly-linux-i686',
descr => 'build tor-browser nightly linux-i686',
......@@ -43,6 +58,12 @@ sub set_tests {
],
publish_dir => 'nightly-linux-i686',
},
{
name => 'incrementals-nightly-linux-i686',
descr => 'create incrementals for tor-browser nightly linux-i686',
type => 'make_incrementals',
publish_dir => 'nightly-linux-i686',
},
{
name => 'nightly-windows-i686',
descr => 'build tor-browser nightly windows-i686',
......@@ -55,6 +76,12 @@ sub set_tests {
],
publish_dir => 'nightly-windows-i686',
},
{
name => 'incrementals-nightly-windows-i686',
descr => 'create incrementals for tor-browser nightly windows-i686',
type => 'make_incrementals',
publish_dir => 'nightly-windows-i686',
},
{
name => 'nightly-windows-x86_64',
descr => 'build tor-browser nightly windows-x86_64',
......@@ -67,6 +94,12 @@ sub set_tests {
],
publish_dir => 'nightly-windows-x86_64',
},
{
name => 'incrementals-nightly-windows-x86_64',
descr => 'create incrementals for tor-browser nightly windows-x86_64',
type => 'make_incrementals',
publish_dir => 'nightly-windows-x86_64',
},
{
name => 'nightly-osx-x86_64',
descr => 'build tor-browser nightly osx-x86_64',
......@@ -79,6 +112,12 @@ sub set_tests {
],
publish_dir => 'nightly-osx-x86_64',
},
{
name => 'incrementals-nightly-osx-x86_64',
descr => 'create incrementals for tor-browser nightly osx-x86_64',
type => 'make_incrementals',
publish_dir => 'nightly-osx-x86_64',
},
{
name => 'nightly-android-armv7',
descr => 'build tor-browser nightly android-armv7',
......@@ -130,6 +169,25 @@ sub set_tests {
];
}
sub make_incrementals {
my ($testsuite, $test) = @_;
$test->{results}{success} = 0;
mkdir 'nightly' unless -d 'nightly';
# Clean the nightly directory
foreach my $subdir (path('nightly')->children) {
unlink $subdir if -l $subdir;
}
foreach my $builddir (path($testsuite->{publish_dir} . '/..')->children) {
if (-f "$builddir/$test->{publish_dir}/sha256sums-unsigned-build.txt") {
symlink("$builddir/$test->{publish_dir}", 'nightly/' . $builddir->basename);
}
}
my @cmd = ('make', 'incrementals-nightly');
run_to_file("$testsuite->{'results-dir'}/$test->{name}.build.txt", @cmd)
or return;
$test->{results}{success} = 1;
}
sub pre_tests {
my ($tbbinfos) = @_;
my $gr = TBBTestSuite::GitRepo->new({
......
details_rbm_build.html
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment