-
Notifications
You must be signed in to change notification settings - Fork 61
/
build.cake
55 lines (44 loc) · 1.23 KB
/
build.cake
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
#tool "nuget:?package=NUnit.ConsoleRunner&version=3.10.0"
var target = Argument("target", "Default");
var version = "1.1.0";
Task("Build")
.Does(() =>
{
var solution = "./src/SalesforceSharp.sln";
NuGetRestore(solution);
MSBuild(solution,
new MSBuildSettings {
Verbosity = Verbosity.Minimal,
Configuration = "Release"
}
);
MSBuild(solution,
new MSBuildSettings {
Verbosity = Verbosity.Minimal,
Configuration = "Debug"
}
);
});
Task("Test")
.Does(() =>
{
NUnit3("./src/SalesforceSharp.UnitTests/bin/Debug/SalesforceSharp.UnitTests.dll");
NUnit3("./src/SalesforceSharp.FunctionalTests/bin/Debug/SalesforceSharp.FunctionalTests.dll");
});
Task("Package")
.Does(() =>{
var nuspecFile = "./src/SalesforceSharp/bin/Release/SalesforceSharp.nuspec";
CopyFile("./src/SalesforceSharp.nuspec", nuspecFile);
NuGetPack(nuspecFile, new NuGetPackSettings{
Version = version,
Verbosity = NuGetVerbosity.Detailed,
}
);
});
Task("Default")
.IsDependentOn("Build")
.IsDependentOn("Test")
.IsDependentOn("Package")
.Does(()=> {
});
RunTarget(target);