Improve codesign script (#71244)

This commit is contained in:
Christopher Fujino
2021-01-14 18:22:08 +00:00
committed by GitHub
parent b29a6bc56b
commit b7f5aef11a
14 changed files with 1182 additions and 386 deletions

View File

@@ -24,7 +24,7 @@ void main() {
FakeArgResults fakeArgResults;
MemoryFileSystem fileSystem;
TestStdio stdio;
Repository repo;
FrameworkRepository repo;
Checkouts checkouts;
FakePlatform platform;
FakeProcessManager processManager;
@@ -39,12 +39,9 @@ void main() {
parentDirectory: fileSystem.directory(checkoutsParentDirectory),
platform: platform,
processManager: processManager,
);
repo = checkouts.addRepo(
platform: platform,
repoType: RepositoryType.framework,
stdio: stdio,
);
repo = FrameworkRepository(checkouts);
});
test('returns false if level not provided', () {
@@ -56,8 +53,6 @@ void main() {
expect(
rollDev(
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
usage: usage,
@@ -75,8 +70,6 @@ void main() {
expect(
rollDev(
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
usage: usage,
@@ -92,8 +85,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -115,8 +113,6 @@ void main() {
try {
rollDev(
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
usage: usage,
@@ -137,8 +133,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -187,8 +188,6 @@ void main() {
rollDev(
usage: usage,
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
),
@@ -206,8 +205,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -267,8 +271,6 @@ void main() {
() => rollDev(
usage: usage,
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
),
@@ -283,8 +285,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -333,8 +340,6 @@ void main() {
() => rollDev(
usage: usage,
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
),
@@ -353,8 +358,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -410,8 +420,6 @@ void main() {
expect(
() => rollDev(
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
usage: usage,
@@ -427,8 +435,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -501,8 +514,6 @@ void main() {
rollDev(
usage: usage,
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
),
@@ -517,8 +528,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -595,8 +611,6 @@ void main() {
rollDev(
usage: usage,
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
),
@@ -611,8 +625,13 @@ void main() {
'clone',
'--',
kUpstreamRemote,
'${checkoutsParentDirectory}checkouts/framework',
'${checkoutsParentDirectory}flutter_conductor_checkouts/framework',
]),
const FakeCommand(command: <String>[
'git',
'rev-parse',
'HEAD',
], stdout: commit),
const FakeCommand(command: <String>[
'git',
'remote',
@@ -684,8 +703,6 @@ void main() {
expect(
rollDev(
argResults: fakeArgResults,
fileSystem: fileSystem,
platform: platform,
repository: repo,
stdio: stdio,
usage: usage,