Skip to content

Commit

Permalink
Fix test program as executable.
Browse files Browse the repository at this point in the history
  • Loading branch information
clown committed May 28, 2020
1 parent cb19000 commit 38e5989
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 3 deletions.
2 changes: 1 addition & 1 deletion AppVeyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ environment:
PROJECT_BIN: 'bin\%PLATFORM%\%CONFIGURATION%\net45'
TEST_TOOL: '..\packages\OpenCover\4.7.922\tools\OpenCover.Console.exe'
TEST_ARGS: 'test --no-restore --no-build --logger:Appveyor'
TEST_FILTERS: '+[Cube*]* -[*]*NativeMethods -[*]*Properties.*'
TEST_FILTERS: '+[Cube*]* -[*]*NativeMethods -[*]*Properties.* -[*]*.Program'
TEST_COVERAGE: 'CoverResults.xml'
TEST_RESULTS: 'TestResults'
clone_folder: 'C:\Cube\%PROJECT_NAME%'
Expand Down
3 changes: 2 additions & 1 deletion Tests/Cube.Core.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@
<RootNamespace>Cube.Tests</RootNamespace>
<AssemblyTitle>Cube.Core UnitTest</AssemblyTitle>
<AssemblyName>Cube.Core.Tests</AssemblyName>
<TargetFramework>net45</TargetFramework>
<OutputType>WinExe</OutputType>
<LangVersion>latest</LangVersion>
<TargetFramework>net45</TargetFramework>
<IsPackable>false</IsPackable>
<EnableDefaultNoneItems>false</EnableDefaultNoneItems>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
Expand Down
2 changes: 1 addition & 1 deletion Tests/Sources/Mixin/AssemblyTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public static IEnumerable<TestCaseData> TestCases
yield return new TestCaseData(typeof(AssemblyTest).Assembly, new Expected
{
Name = "Cube.Core.Tests",
FileName = "Cube.Core.Tests.dll",
FileName = "Cube.Core.Tests.exe",
DirectoryName = @"Tests\bin",
Title = "Cube.Core UnitTest",
Description = "NUnit framework を用いて Cube.Core プロジェクトをテストします。",
Expand Down
45 changes: 45 additions & 0 deletions Tests/Sources/Program.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
/* ------------------------------------------------------------------------- */
//
// Copyright (c) 2010 CubeSoft, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
/* ------------------------------------------------------------------------- */
using System;

namespace Cube.Tests
{
/* --------------------------------------------------------------------- */
///
/// Program
///
/// <summary>
/// Represetns the main program.
/// </summary>
///
/* --------------------------------------------------------------------- */
static class Program
{
/* ----------------------------------------------------------------- */
///
/// Main
///
/// <summary>
/// Represents the main method.
/// </summary>
///
/* ----------------------------------------------------------------- */
[STAThread]
static void Main(string[] args) { }
}
}

0 comments on commit 38e5989

Please sign in to comment.