AssemblyInfo.cs cleanup

pull/2/head
kay.one 13 years ago
parent b43397752e
commit 157bcd8b0f

@ -1,5 +1,6 @@
// ReSharper disable InconsistentNaming
using System;
using System.IO;
using FluentAssertions;
using NUnit.Framework;
@ -9,21 +10,21 @@ namespace NzbDrone.Common.Test
[TestFixture]
public class EnviromentProviderTest
{
readonly EnviromentProvider enviromentController = new EnviromentProvider();
readonly EnviromentProvider enviromentProvider = new EnviromentProvider();
[Test]
public void StartupPath_should_not_be_empty()
{
enviromentController.StartUpPath.Should().NotBeBlank();
Path.IsPathRooted(enviromentController.StartUpPath).Should().BeTrue("Path is not rooted");
enviromentProvider.StartUpPath.Should().NotBeBlank();
Path.IsPathRooted(enviromentProvider.StartUpPath).Should().BeTrue("Path is not rooted");
}
[Test]
public void ApplicationPath_should_not_be_empty()
{
enviromentController.ApplicationPath.Should().NotBeBlank();
Path.IsPathRooted(enviromentController.ApplicationPath).Should().BeTrue("Path is not rooted");
enviromentProvider.ApplicationPath.Should().NotBeBlank();
Path.IsPathRooted(enviromentProvider.ApplicationPath).Should().BeTrue("Path is not rooted");
}
@ -31,7 +32,7 @@ namespace NzbDrone.Common.Test
public void ApplicationPath_should_find_iis_in_current_folder()
{
Directory.CreateDirectory(EnviromentProvider.IIS_FOLDER_NAME);
enviromentController.ApplicationPath.Should().BeEquivalentTo(Directory.GetCurrentDirectory());
enviromentProvider.ApplicationPath.Should().BeEquivalentTo(Directory.GetCurrentDirectory());
}
[Test]
@ -39,5 +40,12 @@ namespace NzbDrone.Common.Test
{
EnviromentProvider.IsProduction.Should().BeFalse();
}
[TestCase("0.0.0.0")]
[TestCase("1.0.0.0")]
public void Application_version_should_not_be_default(string version)
{
enviromentProvider.Version.Should().NotBe(new Version(version));
}
}
}

@ -65,7 +65,6 @@
<Compile Include="EnviromentProviderTest.cs" />
<Compile Include="Fixtures.cs" />
<Compile Include="ProcessProviderTests.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="ServiceControllerTests.cs" />
<Compile Include="WebClientTests.cs" />
</ItemGroup>
@ -86,6 +85,9 @@
<Name>NzbDrone.Test.Dummy</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<Folder Include="Properties\" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.

@ -21,7 +21,7 @@ namespace NzbDrone.Common
new Client
{
ApiKey = "43BBF60A-EB2A-4C1C-B09E-422ADF637265",
ApplicationName = "NZBDrone",
ApplicationName = "NzbDrone",
CurrentException = logEvent.Exception
}.Submit();

@ -58,6 +58,7 @@
<Compile Include="Model\ProcessInfo.cs" />
<Compile Include="ProcessProvider.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Properties\SharedAssemblyInfo.cs" />
<Compile Include="ServiceProvider.cs" />
<Compile Include="WebClientProvider.cs" />
</ItemGroup>

@ -1,36 +1,10 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NzbDrone.Common")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("NzbDrone.Common")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2011")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("b6eaa144-e13b-42e5-a738-c60d89c0f728")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

@ -1,26 +1,18 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NzbDrone.Common.Test")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("NzbDrone.Common.Test")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2011")]
[assembly: AssemblyCompany("www.nzbdrone.com")]
[assembly: AssemblyProduct("NzbDrone")]
[assembly: AssemblyCopyright("GNU General Public v3")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("dc28491a-9f47-4823-a239-0e195d2ee42b")]
[assembly: ComVisible(false)]
// Version information for an assembly consists of the following four values:
//
@ -32,5 +24,4 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyVersion("0.6.0.*")]

@ -186,6 +186,9 @@
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="..\NzbDrone.Common\Properties\SharedAssemblyInfo.cs">
<Link>Properties\SharedAssemblyInfo.cs</Link>
</Compile>
<Compile Include="Constants.cs" />
<Compile Include="Datastore\Connection.cs" />
<Compile Include="Datastore\MigrationLogger.cs" />

@ -1,18 +1,4 @@
// * This program is free software: you can redistribute it and/or modify
// * it under the terms of the GNU General Public License as published by
// * the Free Software Foundation, either version 3 of the License, or
// * (at your option) any later version.
// *
// * This program is distributed in the hope that it will be useful,
// * but WITHOUT ANY WARRANTY; without even the implied warranty of
// * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// * GNU General Public License for more details.
// *
// * You should have received a copy of the GNU General Public License
// * along with this program. If not, see <http://www.gnu.org/licenses/>.
// *
// */
using System.Reflection;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
@ -20,35 +6,9 @@ using System.Runtime.InteropServices;
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NZBDrone.Core")]
[assembly: AssemblyDescription("NZBDrone Core Component")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("www.nzbdrone.com")]
[assembly: AssemblyProduct("NZBDrone")]
[assembly: AssemblyCopyright("GNU General Public v3")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
[assembly: AssemblyTitle("NzbDrone.Core")]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("3C29FEF7-4B07-49ED-822E-1C29DC49BFAB")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.6.0.*")]
[assembly: InternalsVisibleTo("NzbDrone.Core.Test")]

@ -46,6 +46,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\NzbDrone.Common\Properties\SharedAssemblyInfo.cs">
<Link>Properties\SharedAssemblyInfo.cs</Link>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Providers\UpdateProvider.cs" />

@ -1,36 +1,10 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NzbDrone.Update")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("NzbDrone.Update")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2011")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("e4560a3d-8053-4d57-a260-bfe52f4cc357")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: Guid("e4560a3d-8053-4d57-a260-bfe52f4cc357")]

@ -130,15 +130,10 @@ hr
/* Footer */
.timer
.footer
{
text-align: center;
padding: 1px 1px 1px 1px;
color: #065EFE;
}
#footer
{
padding: 1px, 1px, 1px, 1px;
text-align: center;
}
@ -242,4 +237,4 @@ select, button, input[type="button"], input[type="submit"], input[type="reset"]
position: fixed;
top: 30px;
right: 15px;
}
}

@ -17,7 +17,6 @@
margin: 0px;
display: none;
@*Rounded Edges*@
border:1px solid #444444;
-moz-border-radius-bottomright: 8px;
-webkit-border-bottom-right-radius: 8px;
@ -37,7 +36,6 @@
color:#FFFFFF;
@*Rounded Edges*@
border: 1px solid #444444;
border-top: 0px;
-moz-border-radius-bottomright: 10px;

@ -1,17 +1,21 @@
using System;
using System.Web.Mvc;
using NzbDrone.Common;
using NzbDrone.Core.Providers;
using NzbDrone.Core.Providers.Jobs;
using NzbDrone.Web.Models;
namespace NzbDrone.Web.Controllers
{
public class SharedController : Controller
{
private readonly JobProvider _jobProvider;
private readonly EnviromentProvider _enviromentProvider;
public SharedController(JobProvider jobProvider)
public SharedController(JobProvider jobProvider, EnviromentProvider enviromentProvider)
{
_jobProvider = jobProvider;
_enviromentProvider = enviromentProvider;
}
public ActionResult Index()
@ -22,8 +26,8 @@ namespace NzbDrone.Web.Controllers
[ChildActionOnly]
public ActionResult Footer()
{
ViewData["RssTimer"] = _jobProvider.NextScheduledRun(typeof(RssSyncJob)).ToString("yyyyMMddHHmmss");
return PartialView();
return PartialView(new FooterModel { BuildTime = _enviromentProvider.BuildDateTime, Version = _enviromentProvider.Version });
}
[ChildActionOnly]

@ -55,7 +55,7 @@ namespace NzbDrone.Web
protected override IKernel CreateKernel()
{
var kernel = CentralDispatch.NinjectKernel;
Logger.Info("NZBDrone Starting up.");
Logger.Info("NzbDrone Starting up.");
CentralDispatch.DedicateToHost();

@ -0,0 +1,10 @@
using System;
namespace NzbDrone.Web.Models
{
public class FooterModel
{
public Version Version { get; set; }
public DateTime BuildTime { get; set; }
}
}

@ -338,6 +338,9 @@
<Content Include="Content\Images\Unpacking.png" />
<Content Include="Content\jquery.gritter.css" />
<Content Include="Content\Menu.css" />
<Compile Include="..\NzbDrone.Common\Properties\SharedAssemblyInfo.cs">
<Link>Properties\SharedAssemblyInfo.cs</Link>
</Compile>
<Compile Include="App_GlobalResources\EditorLocalization.bg-BG.designer.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
@ -486,6 +489,7 @@
<Compile Include="Helpers\DescriptionExtension.cs" />
<Compile Include="Helpers\HtmlPrefixScopeExtensions.cs" />
<Compile Include="Helpers\IsCurrentActionHelper.cs" />
<Compile Include="Models\CodeFile1.cs" />
<Compile Include="Models\ExistingSeriesModel.cs" />
<Compile Include="Models\AddNewSeriesModel.cs" />
<Compile Include="Models\JobQueueItemModel.cs" />

@ -1,37 +1,7 @@
using System.Reflection;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NZBDrone.Web")]
[assembly: AssemblyDescription("NZBDrone Web Interface")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("www.nzbdrone.com")]
[assembly: AssemblyProduct("NZBDrone")]
[assembly: AssemblyCopyright("GNU General Public v3")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
[assembly: AssemblyTitle("NzbDrone.Web")]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("1ec2c814-7c1e-470d-bbae-59b129b720fd")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("0.6.0.*")]

@ -2,7 +2,7 @@
@using NzbDrone.Web.Models;
@model IEnumerable<NzbDrone.Core.Repository.Series>
@section TitleContent{
NZBDrone
NzbDrone
}
<style>

@ -1,4 +1,4 @@
@model System.Web.Mvc.HandleErrorInfo
@model HandleErrorInfo
@section TitleContent
{

@ -1,5 +1,5 @@
@using NzbDrone.Core
@using NzbDrone.Web.Models
@model FooterModel
<div>
@*NZBDrone @CentralDispatch.Version (@CentralDispatch.BuildDateTime.ToString("MMM d, yyyy"))*@
NzbDrone @Model.Version (@Model.BuildTime.ToString("MMM d, yyyy"))
</div>

@ -4,7 +4,7 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<link rel="SHORTCUT ICON" href="../../favicon.ico" />
<title>NZBDrone</title>
<title>NzbDrone</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<link type="text/css" rel="stylesheet" href="/Content/2011.2.712/telerik.common.min.css" />
<link type="text/css" rel="stylesheet" href="/Content/2011.2.712/telerik.sitefinity.min.css" />
@ -61,7 +61,7 @@
</div>
</div>
<hr />
<div id="footer" class="span-24 last">
<div class="span-24 last footer">
@{Html.RenderAction("Footer", "Shared");}
</div>
</div>

@ -87,6 +87,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\NzbDrone.Common\Properties\SharedAssemblyInfo.cs">
<Link>Properties\SharedAssemblyInfo.cs</Link>
</Compile>
<Compile Include="ApplicationServer.cs">
<SubType>Component</SubType>
</Compile>

@ -5,35 +5,5 @@ using System.Runtime.InteropServices;
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("NZBDrone")]
[assembly: AssemblyDescription("NZBDrone")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("www.nzbdrone.com")]
[assembly: AssemblyProduct("NZBDrone")]
[assembly: AssemblyCopyright("GNU General Public v3")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("67AADCD9-89AA-4D95-8281-3193740E70E5")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.6.0.*")]
[assembly: AssemblyTitle("NzbDrone.exe")]
[assembly: Guid("67AADCD9-89AA-4D95-8281-3193740E70E5")]

@ -112,7 +112,7 @@ namespace NzbDrone.Providers
new Client
{
ApiKey = "43BBF60A-EB2A-4C1C-B09E-422ADF637265",
ApplicationName = "NZBDrone",
ApplicationName = "NzbDrone",
CurrentException = excepion as Exception
}.Submit();
#endif

Loading…
Cancel
Save