Skip to content

Commit

Permalink
Got all test projects working.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jim Buck committed Aug 6, 2016
1 parent c72d1ae commit 57394bc
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 20 deletions.
17 changes: 17 additions & 0 deletions test/dotnet-a/Program.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System;
using System.Threading.Tasks;

namespace ConsoleApplication
{
Expand All @@ -7,6 +8,22 @@ public class Program
public static void Main(string[] args)
{
Console.WriteLine("Hello World!");
_doWork().Wait();
}

private static async Task _doWork()
{
var rand = new Random();
while(true)
{
var num = rand.NextDouble();
if(num < 0.9){
Console.WriteLine("It was a safe result!");
} else {
Console.Error.WriteLine("It was a terrible result!");
}
await Task.Delay(100);
}
}
}
}
Binary file modified test/dotnet-a/bin/Debug/netcoreapp1.0/dotnet-a.dll
Binary file not shown.
2 changes: 1 addition & 1 deletion test/dotnet-a/obj/Debug/netcoreapp1.0/.IncrementalCache
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"inputs":["c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\project.json","c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\project.lock.json","c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\Program.cs"],"outputs":["c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.dll","c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.pdb","c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.deps.json","c:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.runtimeconfig.json"],"buildArguments":{"version-suffix":null}}
{"inputs":["C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\project.json","C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\project.lock.json","C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\Program.cs"],"outputs":["C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.dll","C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.pdb","C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.deps.json","C:\\Projects\\Personal\\playbook\\test\\dotnet-a\\bin\\Debug\\netcoreapp1.0\\dotnet-a.runtimeconfig.json"],"buildArguments":{"version-suffix":null}}
6 changes: 3 additions & 3 deletions test/dotnet-a/obj/Debug/netcoreapp1.0/dotnet-compile-csc.rsp
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
-debug:portable
-nostdlib
-nologo
"c:\Projects\Personal\playbook\test\dotnet-a\obj\Debug\netcoreapp1.0\dotnet-compile.assemblyinfo.cs"
-out:"c:\Projects\Personal\playbook\test\dotnet-a\bin\Debug\netcoreapp1.0\dotnet-a.dll"
"C:\Projects\Personal\playbook\test\dotnet-a\obj\Debug\netcoreapp1.0\dotnet-compile.assemblyinfo.cs"
-out:"C:\Projects\Personal\playbook\test\dotnet-a\bin\Debug\netcoreapp1.0\dotnet-a.dll"
-r:"C:\Users\Jim\.nuget\packages\Microsoft.CSharp\4.0.1\ref\netstandard1.0\Microsoft.CSharp.dll"
-r:"C:\Users\Jim\.nuget\packages\Microsoft.VisualBasic\10.0.1\ref\netstandard1.1\Microsoft.VisualBasic.dll"
-r:"C:\Users\Jim\.nuget\packages\Microsoft.Win32.Primitives\4.0.1\ref\netstandard1.3\Microsoft.Win32.Primitives.dll"
Expand Down Expand Up @@ -82,4 +82,4 @@
-r:"C:\Users\Jim\.nuget\packages\System.Threading.Timer\4.0.1\ref\netstandard1.2\System.Threading.Timer.dll"
-r:"C:\Users\Jim\.nuget\packages\System.Xml.ReaderWriter\4.0.11\ref\netstandard1.3\System.Xml.ReaderWriter.dll"
-r:"C:\Users\Jim\.nuget\packages\System.Xml.XDocument\4.0.11\ref\netstandard1.3\System.Xml.XDocument.dll"
"c:\Projects\Personal\playbook\test\dotnet-a\Program.cs"
"C:\Projects\Personal\playbook\test\dotnet-a\Program.cs"
6 changes: 3 additions & 3 deletions test/dotnet-a/obj/Debug/netcoreapp1.0/dotnet-compile.rsp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
--temp-output:c:\Projects\Personal\playbook\test\dotnet-a\obj\Debug\netcoreapp1.0\
--out:c:\Projects\Personal\playbook\test\dotnet-a\bin\Debug\netcoreapp1.0\dotnet-a.dll
--temp-output:C:\Projects\Personal\playbook\test\dotnet-a\obj\Debug\netcoreapp1.0\
--out:C:\Projects\Personal\playbook\test\dotnet-a\bin\Debug\netcoreapp1.0\dotnet-a.dll
--define:DEBUG
--define:TRACE
--define:NETCOREAPP1_0
Expand Down Expand Up @@ -88,4 +88,4 @@
--reference:C:\Users\Jim\.nuget\packages\System.Threading.Timer\4.0.1\ref\netstandard1.2\System.Threading.Timer.dll
--reference:C:\Users\Jim\.nuget\packages\System.Xml.ReaderWriter\4.0.11\ref\netstandard1.3\System.Xml.ReaderWriter.dll
--reference:C:\Users\Jim\.nuget\packages\System.Xml.XDocument\4.0.11\ref\netstandard1.3\System.Xml.XDocument.dll
c:\Projects\Personal\playbook\test\dotnet-a\Program.cs
C:\Projects\Personal\playbook\test\dotnet-a\Program.cs
4 changes: 2 additions & 2 deletions test/dotnet-a/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}
},
"commands": {
"web": "Microsoft.AspNet.Hosting server.name=Microsoft.AspNet.Server.WebListener server.urls=http://localhost:5001",
"kestrel" : "Microsoft.AspNet.Hosting --server Kestrel --server.urls http://localhost:5004"
"web": "Microsoft.AspNet.Hosting server.name=Microsoft.AspNet.Server.WebListener server.urls=http://localhost:5511",
"kestrel" : "Microsoft.AspNet.Hosting --server Kestrel --server.urls http://localhost:5501"
}
}
1 change: 1 addition & 0 deletions test/dotnet-b/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ public static void Main(string[] args)
.UseContentRoot(Directory.GetCurrentDirectory())
.UseIISIntegration()
.UseStartup<Startup>()
.UseUrls("http://localhost:6016")
.Build();

host.Run();
Expand Down
2 changes: 1 addition & 1 deletion test/dotnet-b/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"pretest": "echo We're about to test...",
"test": "echo ...the tests look good...",
"posttest": "echo ...so we're all done here!"
}
},
"devDependencies": {
"gulp": "3.9.1",
"gulp-concat": "2.6.0",
Expand Down
15 changes: 14 additions & 1 deletion test/node-a/server.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@

var port = 6014;
var http = require('http');
var url = require('url')

console.log('Hello world!');
var server = http.createServer(function (req, res) {
var query = url.parse(req.url,true).query;
var json = JSON.stringify(query, null, 4);
console.log(json);
res.writeHead(200, { 'Content-Type': 'application/json', "Access-Control-Allow-Origin":"*" });
res.end(json);
});

server.listen(6014, () => {
console.log(`Server listening on port "${port}"...`);
});
17 changes: 8 additions & 9 deletions test/node-b/index.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@

let http = require('http');
const PORT = 6014;

let server = http.createServer((request, response) => {
response.end('Request Path: ' + request.url);
});

server.listen(PORT, () => {
console.log(`node-b server listening on: http://localhost:${PORT}`);
});
setInterval(() => {
let randomNum = Math.random();
if(randomNum < 0.9){
process.stdout.write(`It was a great draw! ${randomNum}`);
} else {
process.stderr.write(`It was a bad draw! ${randomNum}`);
}
}, 100);

0 comments on commit 57394bc

Please sign in to comment.