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 option allow_redundancy to rule explicit_type_interface #2313

Merged
merged 6 commits into from
Jul 30, 2018

Conversation

Jeehut
Copy link
Collaborator

@Jeehut Jeehut commented Jul 23, 2018

Fixes #2312.

@SwiftLintBot
Copy link

SwiftLintBot commented Jul 23, 2018

12 Messages
📖 Linting Aerial with this PR took 0.59s vs 0.5s on master (17% slower)
📖 Linting Alamofire with this PR took 3.28s vs 4.42s on master (25% faster)
📖 Linting Firefox with this PR took 12.95s vs 15.73s on master (17% faster)
📖 Linting Kickstarter with this PR took 21.28s vs 23.96s on master (11% faster)
📖 Linting Moya with this PR took 2.45s vs 2.61s on master (6% faster)
📖 Linting Nimble with this PR took 2.17s vs 2.35s on master (7% faster)
📖 Linting Quick with this PR took 0.68s vs 0.79s on master (13% faster)
📖 Linting Realm with this PR took 4.29s vs 4.12s on master (4% slower)
📖 Linting SourceKitten with this PR took 1.34s vs 1.21s on master (10% slower)
📖 Linting Sourcery with this PR took 5.41s vs 5.73s on master (5% faster)
📖 Linting Swift with this PR took 33.69s vs 30.73s on master (9% slower)
📖 Linting WordPress with this PR took 20.71s vs 18.29s on master (13% slower)

Generated by 🚫 Danger

@codecov-io
Copy link

codecov-io commented Jul 23, 2018

Codecov Report

Merging #2313 into master will increase coverage by <.01%.
The diff coverage is 97.82%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #2313      +/-   ##
=========================================
+ Coverage   91.99%     92%   +<.01%     
=========================================
  Files         296     296              
  Lines       14886   14929      +43     
=========================================
+ Hits        13694   13735      +41     
- Misses       1192    1194       +2
Impacted Files Coverage Δ
...ests/ExplicitTypeInterfaceConfigurationTests.swift 100% <100%> (ø) ⬆️
...gurations/ExplicitTypeInterfaceConfiguration.swift 88.88% <100%> (+1.08%) ⬆️
...rameworkTests/ExplicitTypeInterfaceRuleTests.swift 100% <100%> (ø) ⬆️
...intFramework/Rules/ExplicitTypeInterfaceRule.swift 96.42% <92.3%> (-3.58%) ⬇️
...ce/SwiftLintFramework/Rules/WeakDelegateRule.swift 98.18% <0%> (-1.82%) ⬇️
...SwiftLintFramework/Extensions/File+SwiftLint.swift 96.77% <0%> (-0.47%) ⬇️
...e/SwiftLintFramework/Rules/PrivateOutletRule.swift 100% <0%> (+3.33%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f4add39...42cea6e. Read the comment docs.

@Jeehut Jeehut changed the title Make explicit_type_interface compatible with redundant_type_annotation [WIP] Make explicit_type_interface compatible with redundant_type_annotation Jul 24, 2018
@Jeehut
Copy link
Collaborator Author

Jeehut commented Jul 24, 2018

I marked this PR [WIP] for now, as I need to update this to use a custom option following the discussions in #2312.

@Jeehut Jeehut changed the title [WIP] Make explicit_type_interface compatible with redundant_type_annotation Add option allow_redundancy to rule explicit_type_interface Jul 26, 2018
@Jeehut
Copy link
Collaborator Author

Jeehut commented Jul 26, 2018

Just added an option like discussed in #2312 – this is now ready to merge from my point of view. Looking forward to for reviews!

CHANGELOG.md Outdated
@@ -67,6 +67,11 @@
[Marcelo Fabri](https://github.com/marcelofabri)
[#2233](https://github.com/realm/SwiftLint/issues/2233)

* Make rule `explicit_type_interface` compatible with rule
Copy link
Collaborator

Choose a reason for hiding this comment

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

can you move this to the "Enhancements" section and mention the configuration option?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sure, just did.

@Jeehut
Copy link
Collaborator Author

Jeehut commented Jul 27, 2018

I just rebased and moved the changelog entry accordingly.

@@ -35,6 +35,11 @@
* Add `private_only` configuration to `prefixed_toplevel_constant` rule
[Keith Smiley](https://github.com/keith)
[#2315](https://github.com/realm/SwiftLint/pull/2315)

* Make rule `explicit_type_interface` compatible with rule
Copy link
Collaborator

Choose a reason for hiding this comment

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

can you please mention that this is possible with the allow_redundancy configuration key?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done.

@marcelofabri marcelofabri merged commit 0820cd2 into realm:master Jul 30, 2018
@Jeehut Jeehut deleted the explicit-type-interface branch July 30, 2018 07:46
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.

4 participants