TorBrowserBuild.pm 4.1 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
package TBBTestSuite::TestSuite::TorBrowserBuild;

use strict;
use parent 'TBBTestSuite::TestSuite::RBMBuild';

use TBBTestSuite::GitRepo;

sub description {
    'Tor Browser Build';
}

sub type {
    'tor-browser_build';
};

sub set_tests {
    my ($testsuite) = @_;
    $testsuite->{tests} = [
        # Nightly
        {
            name  => 'nightly-linux-x86_64',
            descr => 'build tor-browser nightly linux-x86_64',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'nightly',
                'torbrowser-linux-x86_64',
                'noversiondir',
            ],
            publish_dir => 'nightly-linux-x86_64',
        },
        {
            name  => 'nightly-linux-i686',
            descr => 'build tor-browser nightly linux-i686',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'nightly',
                'torbrowser-linux-i686',
                'noversiondir',
            ],
            publish_dir => 'nightly-linux-i686',
        },
        {
            name  => 'nightly-windows-i686',
            descr => 'build tor-browser nightly windows-i686',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'nightly',
                'torbrowser-windows-i686',
                'noversiondir',
            ],
            publish_dir => 'nightly-windows-i686',
        },
        {
            name  => 'nightly-osx-x86_64',
            descr => 'build tor-browser nightly osx-x86_64',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'nightly',
                'torbrowser-osx-x86_64',
                'noversiondir',
            ],
            publish_dir => 'nightly-osx-x86_64',
        },

        # Alpha
        {
            name  => 'alpha-linux-x86_64',
            descr => 'build tor-browser alpha linux-x86_64',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'alpha',
                'torbrowser-linux-x86_64',
                'noversiondir',
            ],
            publish_dir => 'alpha-linux-x86_64',
        },
        {
            name  => 'alpha-linux-i686',
            descr => 'build tor-browser alpha linux-i686',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'alpha',
                'torbrowser-linux-i686',
                'noversiondir',
            ],
            publish_dir => 'alpha-linux-i686',
        },
        {
            name  => 'alpha-windows-i686',
            descr => 'build tor-browser alpha windows-i686',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'alpha',
                'torbrowser-windows-i686',
                'noversiondir',
            ],
            publish_dir => 'alpha-windows-i686',
        },
        {
            name  => 'alpha-osx-x86_64',
            descr => 'build tor-browser alpha osx-x86_64',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'alpha',
                'torbrowser-osx-x86_64',
                'noversiondir',
            ],
            publish_dir => 'alpha-osx-x86_64',
        },

        # Hardened
        {
            name  => 'hardened-linux-x86_64',
            descr => 'build tor-browser hardened linux-x86_64',
            type  => 'rbm_build',
            project => 'release',
            targets => [
                'hardened',
                'torbrowser-linux-x86_64',
                'noversiondir',
            ],
            publish_dir => 'hardened-linux-x86_64',
        },
    ];
}

sub pre_tests {
    my ($tbbinfos) = @_;
    my $gr = TBBTestSuite::GitRepo->new({
            name => 'tor-browser-build',
139
            git_url => 'https://git.torproject.org/builders/tor-browser-build.git',
140
141
        });
    $gr->clone_fetch;
142
    $gr->cmd('git', 'checkout', 'master');
143
144
145
146
147
148
    chdir $gr->clone_dir();
    system('make', 'submodule-update');
    system('make', 'fetch');
}

1;