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 target to approve new public API #1684

Merged
merged 1 commit into from
Oct 29, 2019

Conversation

blairconrad
Copy link
Member

… I get tired of copying files manually.

@blairconrad
Copy link
Member Author

Technically I think this target should be called "approve" and the current approve something like "check-api", but what can you do?
Also "check-api" is not the best name.

@thomaslevesque
Copy link
Member

Technically I think this target should be called "approve" and the current approve something like "check-api", but what can you do?
Also "check-api" is not the best name.

I don't mind changing the name of the existing target to use approve for the new one. check-api isn't great, but I don't have a better idea...

Copy link
Member

@thomaslevesque thomaslevesque left a comment

Choose a reason for hiding this comment

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

Nice! Thanks @blairconrad, I love the idea. I'm just not sure what the intended usage is (see comment)

@@ -1,5 +1,6 @@
namespace FakeItEasy.Build
{
using System;
Copy link
Member

Choose a reason for hiding this comment

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

What do you need this for? As far as I can tell, the new code only uses classes from System.IO

Copy link
Member Author

Choose a reason for hiding this comment

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

In initial development, I was just spewing messages to the console. I forgot to remove the using when I changed that.

tools/FakeItEasy.Build/Program.cs Show resolved Hide resolved
"accept-api",
() =>
{
foreach (var received in Directory.EnumerateFiles("tests/FakeItEasy.Tests.Approval", "*.received.txt", SearchOption.AllDirectories))
Copy link
Member

Choose a reason for hiding this comment

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

Maybe specify /ApprovedApi in the path, to further reduce the search scope ?

@blairconrad
Copy link
Member Author

I don't mind changing the name of the existing target to use approve for the new one. check-api isn't great, but I don't have a better idea...

validate-api feels slightly better…

or we could leave as is. Or drop the whole thing if you like another approach, such as the environment variables.

@thomaslevesque
Copy link
Member

validate-api feels slightly better…

or we could leave as is. Or drop the whole thing if you like another approach, such as the environment variables.

Or keep the name of the current target, and name the new one force-approve?

@blairconrad
Copy link
Member Author

I think I made your suggested changes. And I squashed. If you like it enough, we could merge. If you have any doubts, we could not!!

@thomaslevesque thomaslevesque merged commit fc14c1e into FakeItEasy:master Oct 29, 2019
@thomaslevesque
Copy link
Member

Thanks @blairconrad!

@blairconrad blairconrad deleted the approve-new-api-task branch October 29, 2019 10:16
@blairconrad
Copy link
Member Author

Thank you!

@blairconrad blairconrad added this to the vNext milestone Oct 29, 2019
@afakebot
Copy link

This change has been released as part of FakeItEasy 6.0.0-beta.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants