From c255375368a38142b9da474227d16a88109a12d8 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 13:35:05 -0700 Subject: [PATCH 01/23] add gendarme support, ignore some rules and fix our implementation --- .gitignore | 2 +- .nuget/packages.config | 1 + README.md | 16 +++ Rakefile | 21 ++- Untappd.Net.sln | 120 ++++++++++++------ assets/gendarme/gendarme.ignore | 60 +++++++++ .../Untappd.Net.UnitTests.csproj | 18 ++- .../Exception/HttpErrorException.cs | 9 ++ src/Untappd.Net/Properties/AssemblyInfo.cs | 4 + src/Untappd.Net/Request/Repository.cs | 20 +-- src/Untappd.Net/Request/RepositoryPost.cs | 19 +++ src/Untappd.Net/Responses/Actions/CheckIn.cs | 4 + src/Untappd.Net/Untappd.Net.csproj | 9 +- 13 files changed, 240 insertions(+), 63 deletions(-) create mode 100644 assets/gendarme/gendarme.ignore diff --git a/.gitignore b/.gitignore index e30f673..ce5124b 100644 --- a/.gitignore +++ b/.gitignore @@ -25,7 +25,7 @@ build/ bld/ [Bb]in/ [Oo]bj/ - +output/ # Visual Studo 2015 cache/options directory .vs/ diff --git a/.nuget/packages.config b/.nuget/packages.config index cbb5d4e..99125be 100644 --- a/.nuget/packages.config +++ b/.nuget/packages.config @@ -4,4 +4,5 @@ + \ No newline at end of file diff --git a/README.md b/README.md index f7510b3..ac09db0 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,22 @@ This is a c# wrapper around the Untappd API. This can be downloaded via [Nuget](https://www.nuget.org/packages/Untappd.Net/), or the [backup feed](https://www.myget.org/F/untappd-net/api/v2). +## Building via command line + +If you wish to build via command line install ruby, and ruby gems. Open up a console in the root directory of this project, and then run the following: + +* `gem install rake` +* `gem install bundle` +* `bundle` +* `rake preflight` + +## My PR is broken, it works in VS! + +if your pull request is broken either one of two things is happening. + +1. Your changes are not mono compatible, which prevent linux users from using your changes. This will only happen if travis ci says your build is broken, but appveyor does not. +2. You have added gendarme violations. You can run gendarme locally by running `rake preflight` from your console. + ## API Coverage Current both Authenticated and Unauthenticated requests. diff --git a/Rakefile b/Rakefile index 22b9648..44078b8 100644 --- a/Rakefile +++ b/Rakefile @@ -23,7 +23,7 @@ desc 'Run the tests' task :test => [:nunit] desc 'Retrieve, Build, Test' -task :preflight => [:retrieve, :build, :test] +task :preflight => [:retrieve, :build, :test, :cs_lint] @@ -37,6 +37,25 @@ test_runner :nunit do |tests| tests.exe = "packages/NUnit.Runners.2.6.4/tools/nunit-console.exe" # executable to run tests with end +task :cs_lint do + + unless Dir.exists?('output') + Dir.mkdir('output') + + end + + + + CMD_PREFIX = "" + if !OS.windows? + CMD_PREFIX = "mono" + end + + sh "#{CMD_PREFIX} packages/Mono.Gendarme.2.11.0.20121120/tools/gendarme.exe src/Untappd.Net/bin/#{Configuration}/Untappd.Net.dll --html output/gendarme.html --severity high+ --ignore assets/gendarme/gendarme.ignore" + +end + + # task :tests => :'tests:unit' #task :ensure_nuget_key do diff --git a/Untappd.Net.sln b/Untappd.Net.sln index d726c13..07347ee 100644 --- a/Untappd.Net.sln +++ b/Untappd.Net.sln @@ -1,38 +1,82 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2013 -VisualStudioVersion = 12.0.31101.0 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Untappd.Net", "src\Untappd.Net\Untappd.Net.csproj", "{D8571A44-2E86-43A3-B64A-2364614C6934}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Untappd.Net.UnitTests", "src\Untappd.Net.UnitTests\Untappd.Net.UnitTests.csproj", "{513A3FB2-6664-40E7-A03E-591D852C42E4}" -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{7175F502-2C45-4728-8693-A6ACDC7D5892}" - ProjectSection(SolutionItems) = preProject - appveyor.yml = appveyor.yml - EndProjectSection -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{8013BAEB-9A81-4ED1-8471-343D16B06D98}" - ProjectSection(SolutionItems) = preProject - .nuget\packages.config = .nuget\packages.config - EndProjectSection -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {D8571A44-2E86-43A3-B64A-2364614C6934}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D8571A44-2E86-43A3-B64A-2364614C6934}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D8571A44-2E86-43A3-B64A-2364614C6934}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D8571A44-2E86-43A3-B64A-2364614C6934}.Release|Any CPU.Build.0 = Release|Any CPU - {513A3FB2-6664-40E7-A03E-591D852C42E4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {513A3FB2-6664-40E7-A03E-591D852C42E4}.Debug|Any CPU.Build.0 = Debug|Any CPU - {513A3FB2-6664-40E7-A03E-591D852C42E4}.Release|Any CPU.ActiveCfg = Release|Any CPU - {513A3FB2-6664-40E7-A03E-591D852C42E4}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 2012 +VisualStudioVersion = 12.0.31101.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Untappd.Net", "src\Untappd.Net\Untappd.Net.csproj", "{D8571A44-2E86-43A3-B64A-2364614C6934}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Untappd.Net.UnitTests", "src\Untappd.Net.UnitTests\Untappd.Net.UnitTests.csproj", "{513A3FB2-6664-40E7-A03E-591D852C42E4}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{7175F502-2C45-4728-8693-A6ACDC7D5892}" + ProjectSection(SolutionItems) = preProject + appveyor.yml = appveyor.yml + EndProjectSection +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{8013BAEB-9A81-4ED1-8471-343D16B06D98}" + ProjectSection(SolutionItems) = preProject + .nuget\packages.config = .nuget\packages.config + EndProjectSection +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {513A3FB2-6664-40E7-A03E-591D852C42E4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {513A3FB2-6664-40E7-A03E-591D852C42E4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {513A3FB2-6664-40E7-A03E-591D852C42E4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {513A3FB2-6664-40E7-A03E-591D852C42E4}.Release|Any CPU.Build.0 = Release|Any CPU + {D8571A44-2E86-43A3-B64A-2364614C6934}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {D8571A44-2E86-43A3-B64A-2364614C6934}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D8571A44-2E86-43A3-B64A-2364614C6934}.Release|Any CPU.ActiveCfg = Release|Any CPU + {D8571A44-2E86-43A3-B64A-2364614C6934}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(NestedProjects) = preSolution + EndGlobalSection + GlobalSection(MonoDevelopProperties) = preSolution + StartupItem = src\Untappd.Net\Untappd.Net.csproj + Policies = $0 + $0.DotNetNamingPolicy = $1 + $1.DirectoryNamespaceAssociation = PrefixedHierarchical + $1.ResourceNamePolicy = FileFormatDefault + $0.TextStylePolicy = $2 + $2.inheritsSet = VisualStudio + $2.inheritsScope = text/plain + $2.scope = text/x-csharp + $0.CSharpFormattingPolicy = $3 + $3.IndentSwitchBody = True + $3.IndentBlocksInsideExpressions = True + $3.AnonymousMethodBraceStyle = NextLine + $3.PropertyBraceStyle = NextLine + $3.PropertyGetBraceStyle = NextLine + $3.PropertySetBraceStyle = NextLine + $3.EventBraceStyle = NextLine + $3.EventAddBraceStyle = NextLine + $3.EventRemoveBraceStyle = NextLine + $3.StatementBraceStyle = NextLine + $3.ElseNewLinePlacement = NewLine + $3.CatchNewLinePlacement = NewLine + $3.FinallyNewLinePlacement = NewLine + $3.WhileNewLinePlacement = DoNotCare + $3.ArrayInitializerWrapping = DoNotChange + $3.ArrayInitializerBraceStyle = NextLine + $3.BeforeMethodDeclarationParentheses = False + $3.BeforeMethodCallParentheses = False + $3.BeforeConstructorDeclarationParentheses = False + $3.NewLineBeforeConstructorInitializerColon = NewLine + $3.NewLineAfterConstructorInitializerColon = SameLine + $3.BeforeDelegateDeclarationParentheses = False + $3.NewParentheses = False + $3.SpacesBeforeBrackets = False + $3.inheritsSet = Mono + $3.inheritsScope = text/x-csharp + $3.scope = text/x-csharp + $0.StandardHeader = $4 + $4.Text = + $4.IncludeInNewFiles = True + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/assets/gendarme/gendarme.ignore b/assets/gendarme/gendarme.ignore new file mode 100644 index 0000000..cf602ce --- /dev/null +++ b/assets/gendarme/gendarme.ignore @@ -0,0 +1,60 @@ +# we have hard coded strings...sue us +R: Gendarme.Rules.Design.PreferUriOverStringRule +A: * + +# We don't really care if our exceptions are not serializable +R: Gendarme.Rules.Serialization.MissingSerializationConstructorRule +A: Untappd.Net + +# Either implement or do not bother +R: Gendarme.Rules.Exceptions.MissingExceptionConstructorsRule +A: Untappd.Net + +# TODO: Implement +R: Gendarme.Rules.BadPractice.DoNotForgetNotImplementedMethodsRule +N: Untappd.Net + + +R: Gendarme.Rules.Design.ConsiderAddingInterfaceRule +T: Untappd.Net.Request.BasicRequest # This class is an abstract class, its inheritors should implement the interface +T: Untappd.Net.SingleObjectArrayConverter # We should figure out how to implement the write json here... +A: Untappd.Net + +# Microsoft says we shouldn't dispose tasks ourselves +R: Gendarme.Rules.Correctness.EnsureLocalDisposalRule +M: System.Void Untappd.Net.Request.Repository/c__async0`1::MoveNext() + +# We use the obsolete constructor for testing +R: Gendarme.Rules.Performance.AvoidUncalledPrivateCodeRule +T: Untappd.Net.Request.Repository + +# we really want constants +R: Gendarme.Rules.BadPractice.AvoidVisibleConstantFieldRule +T: Untappd.Net.Constants + +# for json binding +R: Gendarme.Rules.Naming.AvoidNonAlphanumericIdentifierRule +A: Untappd.Net + +# cannot be helped +R: Gendarme.Rules.Naming.AvoidDeepNamespaceHierarchyRule +A: Untappd.Net + +R: Gendarme.Rules.Maintainability.AvoidLackOfCohesionOfMethodsRule +A: Untappd.Net + +# We need to multiple call +R: Gendarme.Rules.Performance.AvoidRepetitiveCallsToPropertiesRule +T: Untappd.Net.Request.Repository + +# we want to do this here +R: Gendarme.Rules.Exceptions.DoNotSwallowErrorsCatchingNonSpecificExceptionsRule +M: System.Void Untappd.Net.Request.Repository/c__async0`1::MoveNext() + +# We violate case sometimes for json bindings +R: Gendarme.Rules.Naming.UseCorrectCasingRule +A: Untappd.Net + +# TODO: Serialize properly +R: Gendarme.Rules.Serialization.ImplementISerializableCorrectlyRule +T: Untappd.Net.Exception.HttpErrorException diff --git a/src/Untappd.Net.UnitTests/Untappd.Net.UnitTests.csproj b/src/Untappd.Net.UnitTests/Untappd.Net.UnitTests.csproj index 50e05b0..dc85e22 100644 --- a/src/Untappd.Net.UnitTests/Untappd.Net.UnitTests.csproj +++ b/src/Untappd.Net.UnitTests/Untappd.Net.UnitTests.csproj @@ -1,5 +1,5 @@  - + Debug @@ -33,10 +33,6 @@ ..\..\packages\Moq.4.2.1502.0911\lib\net40\Moq.dll - - False - ..\..\packages\Newtonsoft.Json.6.0.8\lib\net45\Newtonsoft.Json.dll - ..\..\packages\NUnitTestAdapter.1.2\lib\nunit.core.dll False @@ -56,10 +52,6 @@ ..\..\packages\NUnitTestAdapter.1.2\lib\NUnit.VisualStudio.TestAdapter.dll False - - False - ..\..\packages\RestSharp.105.0.1\lib\net4\RestSharp.dll - @@ -67,6 +59,12 @@ + + ..\..\packages\Newtonsoft.Json.6.0.8\lib\net45\Newtonsoft.Json.dll + + + ..\..\packages\RestSharp.105.0.1\lib\net4\RestSharp.dll + @@ -98,7 +96,7 @@ - {d8571a44-2e86-43a3-b64a-2364614c6934} + {D8571A44-2E86-43A3-B64A-2364614C6934} Untappd.Net diff --git a/src/Untappd.Net/Exception/HttpErrorException.cs b/src/Untappd.Net/Exception/HttpErrorException.cs index be1e06f..7be45eb 100644 --- a/src/Untappd.Net/Exception/HttpErrorException.cs +++ b/src/Untappd.Net/Exception/HttpErrorException.cs @@ -4,6 +4,7 @@ using RestSharp; namespace Untappd.Net.Exception { + [Serializable] public sealed class HttpErrorException : BaseUntappdException { public override string Message @@ -17,6 +18,14 @@ namespace Untappd.Net.Exception private readonly string _message; public HttpErrorException(IRestRequest request, IRestResponse response) { + if(request == null) + { + throw new ArgumentNullException("request"); + } + if (response == null) + { + throw new ArgumentNullException("response"); + } var code = (int) response.StatusCode; if (code == 200) { diff --git a/src/Untappd.Net/Properties/AssemblyInfo.cs b/src/Untappd.Net/Properties/AssemblyInfo.cs index b99c357..703b1ff 100644 --- a/src/Untappd.Net/Properties/AssemblyInfo.cs +++ b/src/Untappd.Net/Properties/AssemblyInfo.cs @@ -5,6 +5,9 @@ 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. +using System; + + [assembly: AssemblyTitle("Untappd.Net")] [assembly: AssemblyDescription("C# Untappd Wrapper")] [assembly: AssemblyConfiguration("")] @@ -13,6 +16,7 @@ using System.Runtime.InteropServices; [assembly: AssemblyCopyright("Copyright © Microsoft 2015")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] +[assembly: CLSCompliantAttribute(true)] // 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 diff --git a/src/Untappd.Net/Request/Repository.cs b/src/Untappd.Net/Request/Repository.cs index 52b4fde..524606d 100644 --- a/src/Untappd.Net/Request/Repository.cs +++ b/src/Untappd.Net/Request/Repository.cs @@ -13,7 +13,7 @@ namespace Untappd.Net.Request { internal IRestClient Client; internal IRestRequest Request; - private bool FailFast { get; set; } + bool FailFast { get; set; } /// /// Event to listen to when failFast is set to false /// This allows you to capture the excpetion, before its swallowed @@ -65,28 +65,30 @@ namespace Untappd.Net.Request return this; } - private TResult ExecuteRequest() + TResult ExecuteRequest() where TResult : class { return ProcessExecution(Client.Execute(Request)); } - private async Task ExecuteRequestAsync() + async Task ExecuteRequestAsync() where TResult : class { return ProcessExecution(await Client.ExecuteTaskAsync(Request)); } - private TResult ProcessExecution(IRestResponse response) + TResult ProcessExecution(IRestResponse response) where TResult : class { //if the return type is not 200 throw errors if (response.StatusCode != HttpStatusCode.OK) { var excpetion = new HttpErrorException(Request, response); - if (OnExceptionThrown != null) + var eventThrow = OnExceptionThrown; + + if (eventThrow != null) { - OnExceptionThrown(this, new UnhandledExceptionEventArgs(excpetion, FailFast)); + eventThrow(this, new UnhandledExceptionEventArgs(excpetion, FailFast)); } if (FailFast) { @@ -101,9 +103,11 @@ namespace Untappd.Net.Request } catch(System.Exception e) { - if (OnExceptionThrown != null) + var eventThrow = OnExceptionThrown; + + if (eventThrow != null) { - OnExceptionThrown(this, new UnhandledExceptionEventArgs(e, FailFast)); + eventThrow(this, new UnhandledExceptionEventArgs(e, FailFast)); } if (FailFast) { diff --git a/src/Untappd.Net/Request/RepositoryPost.cs b/src/Untappd.Net/Request/RepositoryPost.cs index d3edffa..b971364 100644 --- a/src/Untappd.Net/Request/RepositoryPost.cs +++ b/src/Untappd.Net/Request/RepositoryPost.cs @@ -1,5 +1,6 @@ using System.Threading.Tasks; using Untappd.Net.Authentication; +using System; namespace Untappd.Net.Request { @@ -13,6 +14,15 @@ namespace Untappd.Net.Request /// returns dynamic since often the return doesn't matter public dynamic Post(IAuthenticatedUntappdCredentials credentials, IAction action) { + if (credentials == null) + { + throw new ArgumentNullException("credentials"); + } + if (action == null) + { + throw new ArgumentNullException("action"); + } + return ConfigureRequest(credentials, action.EndPoint, action.BodyParameters, action.RequestMethod) .ExecuteRequest(); } @@ -25,6 +35,15 @@ namespace Untappd.Net.Request /// returns dynamic since often the return doesn't matter public Task PostAsync(IAuthenticatedUntappdCredentials credentials, IAction action) { + if (credentials == null) + { + throw new ArgumentNullException("credentials"); + } + if (action == null) + { + throw new ArgumentNullException("action"); + } + return ConfigureRequest(credentials, action.EndPoint, action.BodyParameters, action.RequestMethod) .ExecuteRequestAsync(); } diff --git a/src/Untappd.Net/Responses/Actions/CheckIn.cs b/src/Untappd.Net/Responses/Actions/CheckIn.cs index 9682366..5989a57 100644 --- a/src/Untappd.Net/Responses/Actions/CheckIn.cs +++ b/src/Untappd.Net/Responses/Actions/CheckIn.cs @@ -53,6 +53,10 @@ namespace Untappd.Net.Responses.Actions get { return _shout; } set { + if (value == null) + { + throw new ArgumentNullException("value"); + } if (value.Length > 140) { throw new ArgumentOutOfRangeException("value", value,"Shout can be no more than 140 characters"); diff --git a/src/Untappd.Net/Untappd.Net.csproj b/src/Untappd.Net/Untappd.Net.csproj index c980f55..830d428 100644 --- a/src/Untappd.Net/Untappd.Net.csproj +++ b/src/Untappd.Net/Untappd.Net.csproj @@ -1,5 +1,5 @@  - + Debug @@ -30,10 +30,6 @@ 4 - - False - ..\..\packages\Newtonsoft.Json.6.0.8\lib\net45\Newtonsoft.Json.dll - ..\..\packages\RestSharp.105.0.1\lib\net4\RestSharp.dll @@ -44,6 +40,9 @@ + + ..\..\packages\Newtonsoft.Json.6.0.8\lib\net45\Newtonsoft.Json.dll + From f7e12c53917d84c3995893a037b395aa372b23e2 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:24:43 -0700 Subject: [PATCH 02/23] fix travis ci link --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ac09db0..ebd4fa0 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ **Master (Windows):** [![Build status](https://ci.appveyor.com/api/projects/status/e21297waldfrso3p/branch/master?svg=true)](https://ci.appveyor.com/project/tparnell8/untappd-net/branch/master) -**Master (Linux):** [![Build status](https://travis-ci.org/tparnell8/Untappd.Net.svg?branch=master) +**Master (Linux):** [![Build Status](https://travis-ci.org/tparnell8/Untappd.Net.svg?branch=master)](https://travis-ci.org/tparnell8/Untappd.Net) **Release:**[![Build status](https://ci.appveyor.com/api/projects/status/e21297waldfrso3p/branch/Release?svg=true)](https://ci.appveyor.com/project/tparnell8/untappd-net/branch/Release) **Code Coverage:** [![Coverage Status](https://coveralls.io/repos/tparnell8/Untappd.Net/badge.svg?branch=master)](https://coveralls.io/r/tparnell8/Untappd.Net?branch=master) From 7af1215c26185844535fe302cc08cd468cefca7c Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:27:12 -0700 Subject: [PATCH 03/23] add cslint to travis --- .travis.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.travis.yml b/.travis.yml index 39ffb1b..22db7cb 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,3 +4,7 @@ script: - xbuild /p:Configuration=Release Untappd.Net.sln - mono ./packages/NUnit.Runners.*/tools/nunit-console.exe ./src/*Tests/bin/Release/*Tests.dll sudo: false +after_script: + - gem install bundle + - bundle + - rake cs_lint From c315891c4d4a6b3fe0e6313e1c5decbb8a5084ae Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:28:00 -0700 Subject: [PATCH 04/23] add ignore for travis test --- assets/gendarme/gendarme.ignore | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/gendarme/gendarme.ignore b/assets/gendarme/gendarme.ignore index cf602ce..c81940f 100644 --- a/assets/gendarme/gendarme.ignore +++ b/assets/gendarme/gendarme.ignore @@ -11,8 +11,8 @@ R: Gendarme.Rules.Exceptions.MissingExceptionConstructorsRule A: Untappd.Net # TODO: Implement -R: Gendarme.Rules.BadPractice.DoNotForgetNotImplementedMethodsRule -N: Untappd.Net +#R: Gendarme.Rules.BadPractice.DoNotForgetNotImplementedMethodsRule +#N: Untappd.Net R: Gendarme.Rules.Design.ConsiderAddingInterfaceRule From 887124158046566791c17b0ef51fa1611b1ac67d Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:33:38 -0700 Subject: [PATCH 05/23] have travis preflight --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 22db7cb..f0d0345 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ script: - xbuild /p:Configuration=Release Untappd.Net.sln - mono ./packages/NUnit.Runners.*/tools/nunit-console.exe ./src/*Tests/bin/Release/*Tests.dll sudo: false -after_script: +script: - gem install bundle - bundle - - rake cs_lint + - rake preflight From 4689bb24ad5688fdc602cd38bea53492445deb51 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:38:08 -0700 Subject: [PATCH 06/23] use https for nuget --- assets/tools.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/tools.rake b/assets/tools.rake index f5ed8c9..22a41c1 100644 --- a/assets/tools.rake +++ b/assets/tools.rake @@ -9,7 +9,7 @@ namespace :tools do FileUtils.mkdir_p("#{NUGET}") File.open("#{NUGET}/nuget.exe", "wb") do |file| - file.write open('http://nuget.org/nuget.exe').read + file.write open('https://nuget.org/nuget.exe').read end end end From 66579ea38668a590b850bb64631c2285ec091806 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:44:11 -0700 Subject: [PATCH 07/23] add after test script to app veyor --- appveyor.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/appveyor.yml b/appveyor.yml index a31bf02..c7ca665 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -25,6 +25,9 @@ build: after_test: - packages\OpenCover.4.5.3723\OpenCover.Console.exe -register:user -filter:"+[Untappd.Net*]* -[*Tests]*" -target:"packages\NUnit.Runners.2.6.4\tools\nunit-console.exe" -targetargs:"/noshadow /domain:single src\Untappd.Net.UnitTests\bin\Release\Untappd.Net.UnitTests.dll" -output:coverage.xml - packages\coveralls.io.1.3.4\tools\coveralls.net.exe --opencover coverage.xml +- gem install bundle +- bundle +- rake cs_lint deploy: - provider: NuGet server: From d7c06721b7541a7ac24dbce7a86a8dd94ffbf309 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 14:49:26 -0700 Subject: [PATCH 08/23] remove fail condition --- assets/gendarme/gendarme.ignore | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/gendarme/gendarme.ignore b/assets/gendarme/gendarme.ignore index c81940f..cf602ce 100644 --- a/assets/gendarme/gendarme.ignore +++ b/assets/gendarme/gendarme.ignore @@ -11,8 +11,8 @@ R: Gendarme.Rules.Exceptions.MissingExceptionConstructorsRule A: Untappd.Net # TODO: Implement -#R: Gendarme.Rules.BadPractice.DoNotForgetNotImplementedMethodsRule -#N: Untappd.Net +R: Gendarme.Rules.BadPractice.DoNotForgetNotImplementedMethodsRule +N: Untappd.Net R: Gendarme.Rules.Design.ConsiderAddingInterfaceRule From a1f1569fcd4e5a585e1aa0f3573aba196f20bb22 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:01:14 -0700 Subject: [PATCH 09/23] add CLS compliant --- src/Untappd.Net/Request/BasicRequest.cs | 6 +++--- src/Untappd.Net/Responses/BeerInfo.cs | 2 +- src/Untappd.Net/Responses/BeerSearch.cs | 2 +- src/Untappd.Net/Responses/BreweryInfo.cs | 2 +- src/Untappd.Net/Responses/BrewerySearch.cs | 2 +- src/Untappd.Net/Responses/Feeds/ActivityFeed.cs | 2 +- src/Untappd.Net/Responses/Feeds/UserActivityFeed.cs | 2 +- src/Untappd.Net/Responses/UserBadges.cs | 2 +- src/Untappd.Net/Responses/UserDistinctBeer.cs | 2 +- src/Untappd.Net/Responses/UserFriends.cs | 2 +- src/Untappd.Net/Responses/UserInfo.cs | 2 +- src/Untappd.Net/Responses/UserWishlist.cs | 2 +- src/Untappd.Net/Responses/VenueInfo.cs | 2 +- 13 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/Untappd.Net/Request/BasicRequest.cs b/src/Untappd.Net/Request/BasicRequest.cs index f3ab311..24cfb70 100644 --- a/src/Untappd.Net/Request/BasicRequest.cs +++ b/src/Untappd.Net/Request/BasicRequest.cs @@ -4,7 +4,7 @@ namespace Untappd.Net.Request { public abstract class BasicRequest { - protected abstract string _EndPoint { get; } + protected abstract string EndPointWithConfiguration { get; } /// /// Pass in the parameter into the request...ie username, brewery, etc. /// @@ -15,9 +15,9 @@ namespace Untappd.Net.Request if (!String.IsNullOrEmpty(parameter)) { parameter = string.Format("/{0}", parameter); - return string.Format(_EndPoint, parameter); + return string.Format(EndPointWithConfiguration, parameter); } - return string.Format(_EndPoint, string.Empty); + return string.Format(EndPointWithConfiguration, string.Empty); } } } diff --git a/src/Untappd.Net/Responses/BeerInfo.cs b/src/Untappd.Net/Responses/BeerInfo.cs index f21f4dd..24c1f1a 100644 --- a/src/Untappd.Net/Responses/BeerInfo.cs +++ b/src/Untappd.Net/Responses/BeerInfo.cs @@ -937,7 +937,7 @@ namespace Untappd.Net.Responses.BeerInfo public class BeerInfo : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/beer/info{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/beer/info{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/BeerSearch.cs b/src/Untappd.Net/Responses/BeerSearch.cs index 2b5d83c..302283d 100644 --- a/src/Untappd.Net/Responses/BeerSearch.cs +++ b/src/Untappd.Net/Responses/BeerSearch.cs @@ -258,7 +258,7 @@ namespace Untappd.Net.Responses.BeerSearch public class BeerSearch : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/search/beer"; } } + protected override string EndPointWithConfiguration { get { return "v4/search/beer"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/BreweryInfo.cs b/src/Untappd.Net/Responses/BreweryInfo.cs index f5365ed..bedc3c1 100644 --- a/src/Untappd.Net/Responses/BreweryInfo.cs +++ b/src/Untappd.Net/Responses/BreweryInfo.cs @@ -908,7 +908,7 @@ namespace Untappd.Net.Responses.BreweryInfo public class BreweryInfo : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/brewery/info{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/brewery/info{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/BrewerySearch.cs b/src/Untappd.Net/Responses/BrewerySearch.cs index 8999559..0b3f615 100644 --- a/src/Untappd.Net/Responses/BrewerySearch.cs +++ b/src/Untappd.Net/Responses/BrewerySearch.cs @@ -146,7 +146,7 @@ namespace Untappd.Net.Responses.BrewerySearch public class BrewerySearch : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/search/brewery"; } } + protected override string EndPointWithConfiguration { get { return "v4/search/brewery"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/Feeds/ActivityFeed.cs b/src/Untappd.Net/Responses/Feeds/ActivityFeed.cs index 01aa653..e52cea6 100644 --- a/src/Untappd.Net/Responses/Feeds/ActivityFeed.cs +++ b/src/Untappd.Net/Responses/Feeds/ActivityFeed.cs @@ -511,7 +511,7 @@ namespace Untappd.Net.Responses.Feeds.ActivityFeed public class ActivityFeed : BasicRequest, IAuthenticatedRequest { - protected override string _EndPoint { get { return "/v4/checkin/recent"; } } + protected override string EndPointWithConfiguration { get { return "/v4/checkin/recent"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/Feeds/UserActivityFeed.cs b/src/Untappd.Net/Responses/Feeds/UserActivityFeed.cs index c78f310..c29ef5e 100644 --- a/src/Untappd.Net/Responses/Feeds/UserActivityFeed.cs +++ b/src/Untappd.Net/Responses/Feeds/UserActivityFeed.cs @@ -478,7 +478,7 @@ namespace Untappd.Net.Responses.Feeds.UserActivityFeed public class UserActivityFeed : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/user/checkins{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/user/checkins{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/UserBadges.cs b/src/Untappd.Net/Responses/UserBadges.cs index 161da3e..2dd2617 100644 --- a/src/Untappd.Net/Responses/UserBadges.cs +++ b/src/Untappd.Net/Responses/UserBadges.cs @@ -207,7 +207,7 @@ namespace Untappd.Net.Responses.UserBadges /// public class UserBadges : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/user/badges{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/user/badges{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/UserDistinctBeer.cs b/src/Untappd.Net/Responses/UserDistinctBeer.cs index 9601394..8fca5b3 100644 --- a/src/Untappd.Net/Responses/UserDistinctBeer.cs +++ b/src/Untappd.Net/Responses/UserDistinctBeer.cs @@ -225,7 +225,7 @@ namespace Untappd.Net.Responses.UserDistinctBeer public class UserDistinctBeers : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/user/beers{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/user/beers{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/UserFriends.cs b/src/Untappd.Net/Responses/UserFriends.cs index 7b1750f..1f55ff0 100644 --- a/src/Untappd.Net/Responses/UserFriends.cs +++ b/src/Untappd.Net/Responses/UserFriends.cs @@ -136,7 +136,7 @@ namespace Untappd.Net.Responses.UserFriends public class UserFriends : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/user/friends{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/user/friends{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/UserInfo.cs b/src/Untappd.Net/Responses/UserInfo.cs index 8ca0d2a..7d62ede 100644 --- a/src/Untappd.Net/Responses/UserInfo.cs +++ b/src/Untappd.Net/Responses/UserInfo.cs @@ -1099,7 +1099,7 @@ namespace Untappd.Net.Responses.UserInfo public class UserInfo : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/user/info{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/user/info{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/UserWishlist.cs b/src/Untappd.Net/Responses/UserWishlist.cs index 8edae98..4ae2b37 100644 --- a/src/Untappd.Net/Responses/UserWishlist.cs +++ b/src/Untappd.Net/Responses/UserWishlist.cs @@ -217,7 +217,7 @@ namespace Untappd.Net.Responses.UserWishlist public class UserWishList : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "/v4/user/wishlist{0}"; } } + protected override string EndPointWithConfiguration { get { return "/v4/user/wishlist{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } diff --git a/src/Untappd.Net/Responses/VenueInfo.cs b/src/Untappd.Net/Responses/VenueInfo.cs index 82fbcac..0b07e61 100644 --- a/src/Untappd.Net/Responses/VenueInfo.cs +++ b/src/Untappd.Net/Responses/VenueInfo.cs @@ -1193,7 +1193,7 @@ namespace Untappd.Net.Responses.VenueInfo public class VenueInfo : BasicRequest, IAuthenticatedRequest, IUnAuthenticatedRequest { - protected override string _EndPoint { get { return "v4/venue/info{0}"; } } + protected override string EndPointWithConfiguration { get { return "v4/venue/info{0}"; } } [JsonProperty("meta")] public Meta Meta { get; set; } From 0f94271b189764cf052ef97eb1bc83775ab74b53 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:20:18 -0700 Subject: [PATCH 10/23] add gendarme to artifacts --- appveyor.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/appveyor.yml b/appveyor.yml index c7ca665..a4b3539 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -41,3 +41,6 @@ deploy: secure: wsN6BzH8ETiXhB9SndP57mHhivqM+CVnghI/+w5XE3bI8K092Z4V4FrJixcrxKnI on: branch: release +artifacts: + - path: output/gendarme.html + name: gendarme From 95dedfeb1e9afeadfe7d5e5ae56755c40a39b6ab Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:21:18 -0700 Subject: [PATCH 11/23] i hate yml --- appveyor.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index a4b3539..453e469 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -42,5 +42,5 @@ deploy: on: branch: release artifacts: - - path: output/gendarme.html - name: gendarme + path: output/gendarme.html + name: gendarme From f5938fb06bf3fff63956ef1c83df7b2cf05c570c Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:37:15 -0700 Subject: [PATCH 12/23] gendarme, always log to console --- Rakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 44078b8..0792408 100644 --- a/Rakefile +++ b/Rakefile @@ -51,7 +51,7 @@ task :cs_lint do CMD_PREFIX = "mono" end - sh "#{CMD_PREFIX} packages/Mono.Gendarme.2.11.0.20121120/tools/gendarme.exe src/Untappd.Net/bin/#{Configuration}/Untappd.Net.dll --html output/gendarme.html --severity high+ --ignore assets/gendarme/gendarme.ignore" + sh "#{CMD_PREFIX} packages/Mono.Gendarme.2.11.0.20121120/tools/gendarme.exe src/Untappd.Net/bin/#{Configuration}/Untappd.Net.dll --html output/gendarme.html --severity high+ --ignore assets/gendarme/gendarme.ignore --console" end From f2e7b5e91c67f26c37f4c2bf3a6abe458d2ffe66 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:46:53 -0700 Subject: [PATCH 13/23] add circle --- circle.yml | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 circle.yml diff --git a/circle.yml b/circle.yml new file mode 100644 index 0000000..a940c17 --- /dev/null +++ b/circle.yml @@ -0,0 +1,7 @@ +dependencies: + pre: + - sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF echo "deb http://download.mono-project.com/repo/debian wheezy main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list + - sudo apt-get update; sudo apt-get install mono-devel mono-complete referenceassemblies-pcl ca-certificates-mono +test: + override: + - rake preflight From 576fca5013ad04a7918ff1a34f9dd40b15902e14 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 15:51:32 -0700 Subject: [PATCH 14/23] just try to install mono normally --- circle.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/circle.yml b/circle.yml index a940c17..7e56091 100644 --- a/circle.yml +++ b/circle.yml @@ -1,7 +1,6 @@ dependencies: pre: - - sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF echo "deb http://download.mono-project.com/repo/debian wheezy main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list - - sudo apt-get update; sudo apt-get install mono-devel mono-complete referenceassemblies-pcl ca-certificates-mono + - sudo apt-get update; sudo apt-get install mono-devel mono-complete test: override: - rake preflight From 2c29210221ac129d61061a62e3a76261589b999b Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:06:36 -0500 Subject: [PATCH 15/23] apt-get with -f --- circle.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/circle.yml b/circle.yml index 7e56091..f35a7ab 100644 --- a/circle.yml +++ b/circle.yml @@ -1,6 +1,6 @@ dependencies: pre: - - sudo apt-get update; sudo apt-get install mono-devel mono-complete + - sudo apt-get update; sudo apt-get install mono-devel mono-complete -f test: override: - rake preflight From 3db9311dc01d57f4594a8d40b58048910b0949b9 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:08:38 -0500 Subject: [PATCH 16/23] ensure local disposed in asm --- assets/gendarme/gendarme.ignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/gendarme/gendarme.ignore b/assets/gendarme/gendarme.ignore index cf602ce..04e3853 100644 --- a/assets/gendarme/gendarme.ignore +++ b/assets/gendarme/gendarme.ignore @@ -22,7 +22,7 @@ A: Untappd.Net # Microsoft says we shouldn't dispose tasks ourselves R: Gendarme.Rules.Correctness.EnsureLocalDisposalRule -M: System.Void Untappd.Net.Request.Repository/c__async0`1::MoveNext() +A: Untappd.Net # We use the obsolete constructor for testing R: Gendarme.Rules.Performance.AvoidUncalledPrivateCodeRule From c006a4bc8928c059d5673bc6316f2f2856234ff9 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:13:06 -0500 Subject: [PATCH 17/23] just install mono full --- circle.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/circle.yml b/circle.yml index f35a7ab..940b67c 100644 --- a/circle.yml +++ b/circle.yml @@ -1,6 +1,6 @@ dependencies: pre: - - sudo apt-get update; sudo apt-get install mono-devel mono-complete -f + - sudo apt-get update; sudo apt-get install mono-complete test: override: - rake preflight From e4593613becd5cf98aad3851a8b518391a75c0ed Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:16:43 -0500 Subject: [PATCH 18/23] try 2 --- circle.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/circle.yml b/circle.yml index 940b67c..70fbe77 100644 --- a/circle.yml +++ b/circle.yml @@ -1,6 +1,6 @@ dependencies: pre: - - sudo apt-get update; sudo apt-get install mono-complete + - sudo apt-get update; sudo apt-get install -f mono-complete test: override: - rake preflight From ffbe89292e529142554fc40e1488c8c0e8e68925 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:19:33 -0500 Subject: [PATCH 19/23] what version of mono do you use? --- circle.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/circle.yml b/circle.yml index 70fbe77..982bb64 100644 --- a/circle.yml +++ b/circle.yml @@ -1,6 +1,7 @@ dependencies: pre: - - sudo apt-get update; sudo apt-get install -f mono-complete + - sudo apt-get update; + - mono --version test: override: - rake preflight From 78d16d99dfd804de42d13ab088795422a9cf1db3 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:26:51 -0500 Subject: [PATCH 20/23] try3 --- circle.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/circle.yml b/circle.yml index 982bb64..1eb96cd 100644 --- a/circle.yml +++ b/circle.yml @@ -1,7 +1,8 @@ dependencies: pre: - sudo apt-get update; - - mono --version + - mozroots + - mozroots --import --sync test: override: - rake preflight From db3c2a490b628836c732ab3292ca51b602f82204 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:29:21 -0500 Subject: [PATCH 21/23] try4 --- circle.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/circle.yml b/circle.yml index 1eb96cd..c6550c9 100644 --- a/circle.yml +++ b/circle.yml @@ -1,8 +1,7 @@ dependencies: pre: - - sudo apt-get update; + - sudo apt-get update; sudo apt-get install mono-devel - mozroots - - mozroots --import --sync test: override: - rake preflight From eeb47de338f7b8cf7d42346c374b49442ae61d47 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:31:02 -0500 Subject: [PATCH 22/23] remove mozroots call --- circle.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/circle.yml b/circle.yml index c6550c9..999d78d 100644 --- a/circle.yml +++ b/circle.yml @@ -1,7 +1,6 @@ dependencies: pre: - sudo apt-get update; sudo apt-get install mono-devel - - mozroots test: override: - rake preflight From 0cee50fa433c7c2ab198969a5394d3e5a9ae7418 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 19 Jun 2015 20:35:19 -0500 Subject: [PATCH 23/23] only get packages from src sub folder --- assets/tools.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/tools.rake b/assets/tools.rake index 22a41c1..beca1da 100644 --- a/assets/tools.rake +++ b/assets/tools.rake @@ -30,7 +30,7 @@ namespace :tools do # Make sure we get solution-level deps sh "#{CMD_PREFIX} #{NUGET}/nuget.exe i .nuget/packages.config -o packages" - FileList["**/packages.config"].each { |filepath| + FileList["src/**/packages.config"].each { |filepath| sh "#{CMD_PREFIX} #{NUGET}/nuget.exe i #{filepath} -o packages" } end