Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/packagesmd #384

Merged
merged 4 commits into from
Sep 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 30 additions & 30 deletions PACKAGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,33 +7,33 @@
2. This package is widely used and is actively maintained.
3. It is open source.

| Package | Source Code | Version | License | Purpose | Additional Risk Assessment |
| ------- | ------------| --------| ------- | ------- | -------------------------- |
| CommandLineParser | [GitHub](https://github.com/commandlineparser/commandline) | [2.8.0](https://www.nuget.org/packages/CommandLineParser/2.8.0) | [MIT](https://opensource.org/licenses/MIT)| Command line argument parsing | |
| CsvHelper | [GitHub](https://github.com/JoshClose/CsvHelper) | [15.0.5](https://www.nuget.org/packages/CsvHelper/15.0.5) | [MS-PL and Apache 2.0](https://github.com/JoshClose/CsvHelper/blob/master/LICENSE.txt)| Writting reports out to CSV reports | |
| fo-dicom.NetCore | [GitHub](https://github.com/fo-dicom/fo-dicom) | [4.0.6](https://www.nuget.org/packages/fo-dicom.NetCore/4.0.6) | [MS-PL](https://opensource.org/licenses/MS-PL) | | |
| HIC.DicomTypeTranslation | [GitHub](https://github.com/HicServices/DicomTypeTranslation) | [2.3.1](https://www.nuget.org/packages/HIC.DicomTypeTranslation/2.3.1) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Translate dicom types into C# / database types | |
| HIC.FAnsiSql | [GitHub](https://github.com/HicServices/FansiSql) | [1.0.5](https://www.nuget.org/packages/HIC.FAnsiSql/1.0.5) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Database abstraction layer | |
| HIC.RDMP.Dicom | [GitHub](https://github.com/HicServices/RdmpDicom) | [2.1.10](https://www.nuget.org/packages/HIC.RDMP.Dicom/2.1.10) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | RDMP Plugin containing data load / pipeline components for imaging, reading dicom files etc | |
| HIC.RDMP.Plugin | [GitHub](https://github.com/HicServices/RDMP) | [4.1.8](https://www.nuget.org/packages/HIC.RDMP.Plugin/4.1.8) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Interact with RDMP objects, base classes for plugin components etc | |
| JetBrains.Annotations | | [2020.1.0](https://www.nuget.org/packages/JetBrains.Annotations/2020.1.0) |[MIT](https://opensource.org/licenses/MIT) | Static analysis tool | |
| Magick.NET-Q16-AnyCPU | [GitHub](https://github.com/dlemstra/Magick.NET) | [7.21.1](https://www.nuget.org/packages/Magick.NET-Q16-AnyCPU/7.21.1) | [Apache License v2](https://github.com/dlemstra/Magick.NET/blob/master/License.txt) | The .NET library for [ImageMagick](https://imagemagick.org/index.php) | |
| Microsoft.CodeAnalysis.CSharp.Scripting | [GitHub](https://github.com/dotnet/roslyn) | [3.7.0](https://www.nuget.org/packages/Microsoft.CodeAnalysis.CSharp.Scripting/3.7.0) | [MIT](https://opensource.org/licenses/MIT) | Supports dynamic rules for cohort extraction logic | |
| Microsoft.Extensions.Caching.Memory | [GitHub](https://github.com/dotnet/extensions) | [3.1.7](https://www.nuget.org/packages/Microsoft.Extensions.Caching.Memory/3.1.7) | [Apache 2.0](https://www.nuget.org/packages/Microsoft.Extensions.Caching.Memory/3.1.7/License) | Caching ID mappings retrieved from Redis/MySQL |
| MongoDB.Driver | [GitHub](https://github.com/mongodb/mongo-csharp-driver) |[2.11.1](https://www.nuget.org/packages/MongoDB.Driver/2.11.1)| [Apache 2.0](https://www.nuget.org/packages/MongoDB.Driver/2.11.1/License) | For writting/reading dicom tags into MongoDb databases|
| NLog | [GitHub](https://github.com/NLog/NLog) | [4.6.4](https://www.nuget.org/packages/NLog/4.6.4) | [BSD 3-Clause](https://github.com/NLog/NLog/blob/dev/LICENSE.txt) | Flexible user configurable logging | |
| Newtonsoft.Json | [GitHub](https://github.com/JamesNK/Newtonsoft.Json) | [12.0.3](https://www.nuget.org/packages/Newtonsoft.Json/12.0.3) | [MIT](https://opensource.org/licenses/MIT) | Serialization of objects for sharing/transmission |
| RabbitMQ.Client | [GitHub](https://github.com/rabbitmq/rabbitmq-dotnet-client) | [5.1.2](https://www.nuget.org/packages/RabbitMQ.Client/5.1.2) | [Apache License v2 / MPL 1.1](https://github.com/rabbitmq/rabbitmq-dotnet-client/blob/master/LICENSE) | Handles messaging between microservices | |
| SecurityCodeScan | [GitHub](https://security-code-scan.github.io/) | [3.5.3](https://www.nuget.org/packages/SecurityCodeScan/3.5.3) | [LGPL 3.0](https://opensource.org/licenses/lgpl-3.0.html) | Scans code for security issues during build | |
| StackExchange.Redis | [GitHub](https://github.com/StackExchange/StackExchange.Redis) | [2.1.58](https://www.nuget.org/packages/StackExchange.Redis/2.1.58) |[MIT](https://opensource.org/licenses/MIT) | Required for RedisSwapper | |
| Stanford.NLP.CoreNLP | [GitHub Pages](https://sergey-tihon.github.io/Stanford.NLP.NET/) | [3.9.2](https://www.nuget.org/packages/Stanford.NLP.CoreNLP/3.9.2) | [GNU v2](https://github.com/sergey-tihon/Stanford.NLP.NET/blob/master/LICENSE.txt)| Name / Organisation detection in text | |
| System.Drawing.Common | [GitHub](https://github.com/dotnet/corefx) | [4.7.0](https://www.nuget.org/packages/System.Drawing.Common/4.7.0) | [MIT](https://opensource.org/licenses/MIT) | Supports reading pixel data | |
| System.IO.Abstractions | [GitHub](https://github.com/System-IO-Abstractions/System.IO.Abstractions) | [12.1.1](https://www.nuget.org/packages/System.IO.Abstractions/12.1.1) | [MIT](https://opensource.org/licenses/MIT) | Makes file system injectable in tests | |
| System.IO.FileSystem | [GitHub](https://github.com/dotnet/corefx) | [4.3.0](https://www.nuget.org/packages/System.IO.FileSystem/4.3.0) |[MIT](https://opensource.org/licenses/MIT) | File I/O | |
| System.Security.AccessControl | [GitHub](https://github.com/dotnet/corefx) | [4.7.0](https://www.nuget.org/packages/System.Security.AccessControl/4.7.0) |[MIT](https://opensource.org/licenses/MIT) | File access perimssions| |
| Terminal.Gui | [GitHub](https://github.com/migueldeicaza/gui.cs/) | [0.89.4](https://www.nuget.org/packages/Terminal.Gui/0.89.4) |[MIT](https://opensource.org/licenses/MIT) | Console GUI library | |
| Tesseract | [GitHub](https://github.com/charlesw/tesseract/) | [4.1.0-beta1](https://www.nuget.org/packages/Tesseract/4.1.0-beta1) |[Apache License v2](https://github.com/charlesw/tesseract/blob/master/LICENSE.txt) | Optical Character Recognition in Dicom Pixel data| |
| YamlDotNet | [GitHub](https://github.com/aaubry/YamlDotNet) | [8.1.2](https://www.nuget.org/packages/YamlDotNet/8.1.2) | [MIT](https://opensource.org/licenses/MIT) |Loading configuration files|
| fo-dicom.Drawing | [GitHub](https://github.com/fo-dicom/fo-dicom) | [4.0.6](https://www.nuget.org/packages/fo-Dicom.Drawing/4.0.6) | [MS-PL](https://opensource.org/licenses/MS-PL)| Support library for reading DICOM pixel data | |
| coveralls.io | [GitHub](https://github.com/coveralls-net/coveralls.net) | [1.4.2](https://www.nuget.org/packages/coveralls.io/1.4.2) | [GNU](https://github.com/coveralls-net/coveralls.net#license)| Uploader for dot net coverage reports to Coveralls.io | |
| OpenCover | [GitHub](https://github.com/OpenCover/opencover) | [4.7.922](https://www.nuget.org/packages/OpenCover/4.7.922) |[MIT Compatible](https://github.com/OpenCover/opencover/blob/master/LICENSE) | Calculates code coverage for tests| |
| Package | Source Code | License | Purpose
| ------- | ------------| ------- | ------- |
| CommandLineParser | [GitHub](https://github.com/commandlineparser/commandline) | [MIT](https://opensource.org/licenses/MIT)| Command line argument parsing |
| CsvHelper | [GitHub](https://github.com/JoshClose/CsvHelper) | [MS-PL and Apache 2.0](https://github.com/JoshClose/CsvHelper/blob/master/LICENSE.txt)| Writting reports out to CSV reports |
| fo-dicom.NetCore | [GitHub](https://github.com/fo-dicom/fo-dicom) | [MS-PL](https://opensource.org/licenses/MS-PL) | |
| HIC.DicomTypeTranslation | [GitHub](https://github.com/HicServices/DicomTypeTranslation) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Translate dicom types into C# / database types |
| HIC.FAnsiSql | [GitHub](https://github.com/HicServices/FansiSql) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Database abstraction layer |
| HIC.RDMP.Dicom | [GitHub](https://github.com/HicServices/RdmpDicom) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | RDMP Plugin containing data load / pipeline components for imaging, reading dicom files etc |
| HIC.RDMP.Plugin | [GitHub](https://github.com/HicServices/RDMP) | [GPL 3.0](https://www.gnu.org/licenses/gpl-3.0.html) | Interact with RDMP objects, base classes for plugin components etc |
| JetBrains.Annotations | |[MIT](https://opensource.org/licenses/MIT) | Static analysis tool |
| Magick.NET-Q16-AnyCPU | [GitHub](https://github.com/dlemstra/Magick.NET) | [Apache License v2](https://github.com/dlemstra/Magick.NET/blob/master/License.txt) | The .NET library for [ImageMagick](https://imagemagick.org/index.php) |
| Microsoft.CodeAnalysis.CSharp.Scripting | [GitHub](https://github.com/dotnet/roslyn) | [MIT](https://opensource.org/licenses/MIT) | Supports dynamic rules for cohort extraction logic |
| Microsoft.Extensions.Caching.Memory | [GitHub](https://github.com/dotnet/extensions) | [Apache 2.0](https://www.nuget.org/packages/Microsoft.Extensions.Caching.Memory/3.1.7/License) | Caching ID mappings retrieved from Redis/MySQL
| MongoDB.Driver | [GitHub](https://github.com/mongodb/mongo-csharp-driver) | [Apache 2.0](https://www.nuget.org/packages/MongoDB.Driver/2.11.1/License) | For writting/reading dicom tags into MongoDb databases
| NLog | [GitHub](https://github.com/NLog/NLog) | [BSD 3-Clause](https://github.com/NLog/NLog/blob/dev/LICENSE.txt) | Flexible user configurable logging |
| Newtonsoft.Json | [GitHub](https://github.com/JamesNK/Newtonsoft.Json) | [MIT](https://opensource.org/licenses/MIT) | Serialization of objects for sharing/transmission
| RabbitMQ.Client | [GitHub](https://github.com/rabbitmq/rabbitmq-dotnet-client) | [Apache License v2 / MPL 1.1](https://github.com/rabbitmq/rabbitmq-dotnet-client/blob/master/LICENSE) | Handles messaging between microservices |
| SecurityCodeScan | [GitHub](https://security-code-scan.github.io/) | [LGPL 3.0](https://opensource.org/licenses/lgpl-3.0.html) | Scans code for security issues during build |
| StackExchange.Redis | [GitHub](https://github.com/StackExchange/StackExchange.Redis) |[MIT](https://opensource.org/licenses/MIT) | Required for RedisSwapper |
| Stanford.NLP.CoreNLP | [GitHub Pages](https://sergey-tihon.github.io/Stanford.NLP.NET/) | [GNU v2](https://github.com/sergey-tihon/Stanford.NLP.NET/blob/master/LICENSE.txt)| Name / Organisation detection in text |
| System.Drawing.Common | [GitHub](https://github.com/dotnet/corefx) | [MIT](https://opensource.org/licenses/MIT) | Supports reading pixel data |
| System.IO.Abstractions | [GitHub](https://github.com/System-IO-Abstractions/System.IO.Abstractions) | [MIT](https://opensource.org/licenses/MIT) | Makes file system injectable in tests |
| System.IO.FileSystem | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | File I/O |
| System.Security.AccessControl | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | File access perimssions|
| Terminal.Gui | [GitHub](https://github.com/migueldeicaza/gui.cs/) |[MIT](https://opensource.org/licenses/MIT) | Console GUI library |
| Tesseract | [GitHub](https://github.com/charlesw/tesseract/) |[Apache License v2](https://github.com/charlesw/tesseract/blob/master/LICENSE.txt) | Optical Character Recognition in Dicom Pixel data|
| YamlDotNet | [GitHub](https://github.com/aaubry/YamlDotNet) | [MIT](https://opensource.org/licenses/MIT) |Loading configuration files
| fo-dicom.Drawing | [GitHub](https://github.com/fo-dicom/fo-dicom) | [MS-PL](https://opensource.org/licenses/MS-PL)| Support library for reading DICOM pixel data |
| coveralls.io | [GitHub](https://github.com/coveralls-net/coveralls.net) | [GNU](https://github.com/coveralls-net/coveralls.net#license)| Uploader for dot net coverage reports to Coveralls.io |
| OpenCover | [GitHub](https://github.com/OpenCover/opencover) |[MIT Compatible](https://github.com/OpenCover/opencover/blob/master/LICENSE) | Calculates code coverage for tests|
39 changes: 15 additions & 24 deletions tests/common/Smi.Common.Tests/NuspecIsCorrectTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,11 @@ public void TestDependencyCorrect(string csproj, string nuspec, string packagesM
string packageDependency = d.Groups[1].Value;
string versionDependency = d.Groups[2].Value;

if (packageDependency.Equals(package))
{
Assert.AreEqual(version, versionDependency,
"Package {0} is version {1} in {2} but version {3} in {4}", package, version, csproj,
versionDependency, nuspec);
found = true;
}
if (!packageDependency.Equals(package)) continue;
Assert.AreEqual(version, versionDependency,
"Package {0} is version {1} in {2} but version {3} in {4}", package, version, csproj,
versionDependency, nuspec);
found = true;
}

if (!found)
Expand All @@ -110,27 +108,20 @@ public void TestDependencyCorrect(string csproj, string nuspec, string packagesM


//And make sure it appears in the packages.md file
if (packagesMarkdown != null)
if (packagesMarkdown == null) continue;
found = false;
foreach (string line in File.ReadAllLines(packagesMarkdown))
{
found = false;
foreach (string line in File.ReadAllLines(packagesMarkdown))
if (Regex.IsMatch(line, @"[\s[]" + Regex.Escape(package) + @"[\s\]]", RegexOptions.IgnoreCase))
{
if (Regex.IsMatch(line, @"[\s[]" + Regex.Escape(package) + @"[\s\]]", RegexOptions.IgnoreCase))
{
int count = new Regex(Regex.Escape(version)).Matches(line).Count;

Assert.GreaterOrEqual(count, 2,
"Markdown file {0} did not contain 2 instances of the version {1} for package {2} in {3}",
packagesMarkdown, version, package, csproj);
found = true;
}
found = true;
}

if (!found)
Assert.Fail("Package {0} in {1} is not documented in {2}. Recommended line is:\r\n{3}", package,
csproj, packagesMarkdown,
BuildRecommendedMarkdownLine(package, version));
}

if (!found)
Assert.Fail("Package {0} in {1} is not documented in {2}. Recommended line is:\r\n{3}", package,
csproj, packagesMarkdown,
BuildRecommendedMarkdownLine(package, version));
}
}

Expand Down