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

Add Repository Lib #7

Merged
merged 5 commits into from
Dec 13, 2019
Merged

Add Repository Lib #7

merged 5 commits into from
Dec 13, 2019

Conversation

JohnMcPMS
Copy link
Member

@JohnMcPMS JohnMcPMS commented Dec 12, 2019

Changes

Adds a new static lib for holding code related to repositories. This initial checkin adds a simple C++ RAII wrapper around basic SQLite functionality. It also adds catch2 and a test exe project that will target the repository lib. A pair of simple tests are there to exercise basic SQLite functionality and flow.

As Component Governance cannot easily detect our use of catch2, an explicit reference is added via cgmanifest.json.

Tested

All of the public methods of the SQLite wrapper classes are exercised via the two tests.

The PR also adds some tasks to the pipeline to run the test and publish the results, failing the build if there are any failures.

@JohnMcPMS JohnMcPMS requested a review from a team as a code owner December 12, 2019 03:08
@@ -0,0 +1,14 @@
{
Copy link
Contributor

@msftrubengu msftrubengu Dec 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this file for? #Resolved

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Manual declaration of OSS in use. The automated system does not detect git dependencies well.


In reply to: 357321099 [](ancestors = 357321099)

bool Step();

// Gets the value of the specified column from the current row.
// The index is 0 based.
Copy link
Contributor

@msftrubengu msftrubengu Dec 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What mad man would think otherwise? #Resolved

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The mad man that made the bind functions 1 based.


In reply to: 357325097 [](ancestors = 357325097)

@@ -0,0 +1,114 @@
// Copyright (c) Microsoft Corporation.
Copy link
Contributor

@yao-msft yao-msft Dec 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copyright (c) Microsoft Corp [](start = 3, length = 28)

Better to name the file SQLiteWrapperTests.cpp? #WontFix

@@ -31,6 +31,17 @@ steps:
configuration: '$(buildConfiguration)'
msbuildArgs: '/p:AppxBundlePlatforms="$(buildPlatform)" /p:AppxPackageDir="$(appxPackageDir)" /p:AppxBundle=Always /p:UapAppxPackageBuildMode=StoreUpload'

- task: CmdLine@2
inputs:
script: 'RepositoryLibTests.exe -s -r junit -o TEST-RepositoryLib-$(_artifact).xml'
Copy link
Contributor

@yao-msft yao-msft Dec 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RepositoryLibTests.exe [](start = 13, length = 22)

So for every new test project added, I need to update here? #Resolved

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this script would need to expand to include each test exe. While we could put them all together, I like the small rebuild size for individual ones.


In reply to: 357376907 [](ancestors = 357376907)

Copy link
Contributor

@yao-msft yao-msft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@JohnMcPMS JohnMcPMS merged commit fa3883c into microsoft:master Dec 13, 2019
@JohnMcPMS JohnMcPMS deleted the repolib branch December 16, 2019 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants