-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Include FluxC 2.99.0
modules with their git history and unit tests
#21304
Draft
wzieba
wants to merge
9,061
commits into
trunk
Choose a base branch
from
fluxc_raw_history_with_example_tests
base: trunk
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+140,040
−0
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Utilities to improve observing products
…point Add "stats/emails/summary" endpoint
[Crash Fix] Update Woo-specific migration to run only for WooCommerce
…-FluxC-Android into origin/add-total-subscribers-card
Merge Release/2.77.1 to trunk
…s-type Add SUBSCRIBERS as SubscriberType
…-FluxC-Android into origin/add-total-subscribers-card
Fixes: try to catch exception for fun getListItems()
Fixes: publish post when device time is set manually
…n-to-followers-endpoint Add "all" type option to followers endpoint
…ctives-endpoint Add campaigns/objectives endpoint
…a-v2 Add support to fetch WP media using v2 endpoint
…ovider-method-for-new-dao Adds missing provider method for new Objective DAO
This dependency was incorrectly removed and replaced by its corresponding 'eventbus-java' transitive dependency, assuming that is not required. However, after further testing it was revealed that this parent 'eventbus' dependency, which is actually 'android' specific is indeed necessary. If it is not provided on the classpath then an app will crash with the below runtime exception: ------------------------------------------------------------------------ java.lang.RuntimeException: Unable to create application xyz: java.lang .RuntimeException: It looks like you are using EventBus on Android, make sure to add the "eventbus" Android library to your dependencies. ------------------------------------------------------------------------ For more info see: - EventBus.register(...): https://github.com/greenrobot/EventBus/blob/ 0194926b3bcf70cc0d7bfd3c5da16708dd5ab876/EventBus/src/org/greenrobot/ eventbus/EventBus.java#L143-L147 - !AndroidDependenciesDetector.areAndroidComponentsAvailable(): https://github.com/greenrobot/EventBus/blob/ 0194926b3bcf70cc0d7bfd3c5da16708dd5ab876/EventBus/src/org/greenrobot/ eventbus/android/AndroidDependenciesDetector.java#L25-L36
…-android-dependency [Deps] Add Back EventBus Android Dependency
Product Password using site credentials
…ent-anr Revert "[ANR fix] Move UserAgent initialization to a background thread"
…ive-parameter-fluxc Add new objective parameter to create campaign request
…overability-crash Split Link header values into different items
…ld-nullable Make objective field nullable
…aw_history_with_example_tests
Quality Gate failedFailed conditions See analysis details on SonarCloud Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
Generated by 🚫 Danger |
📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
|
📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
|
1 task
wzieba
changed the title
[WIP] FluxC with tests from
Include FluxC Oct 16, 2024
example
2.99.0
modules with their git history and unit tests
wzieba
added
the
Do Not Merge
In PRs with this label, our automation will fail a require check, preventing accidental merging
label
Oct 16, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Do Not Merge
In PRs with this label, our automation will fail a require check, preventing accidental merging
unit-tests-exemption
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Tip
This PR is a result of
git filter-repo
filtering. To read more about the process, please see internal post: paqN3M-m2-p2. The project discussed there is different, but the same rules apply here.This PR introduces source code of 3 FluxC modules:
fluxc
,fluxc-annotations
andfluxc-processor
in version2.99.0
into WordPress-Android codebase.It also includes unit tests that were included in
example
module, but were technically unit tests offluxc
. To not includeexample
module, I had to alter the git history and modify paths: see the step 1 below.This PR does not integrate these modules to the build. As you can see below, we only include 3 directories.
The attached git-history is extracted from the FluxC repository using
git filter-repo
. The process contains following phases.1. Replace unit tests path
Because unit tests in FluxC project were placed in
example
module, which I didn't want to move, I had to alter the git history and modify paths, effectively movingtest
directory ofexample
module tofluxc
:git filter-repo \ --path-rename example/src/test:fluxc/src/test \ --force #needed when filtering after tag checkout
2. Leave only FluxC modules
In this step, we strip all not needed directories and files, leaving only FluxC ones:
git filter-repo \ --path fluxc-annotations \ --path fluxc-processor \ --path fluxc \ --force #needed when filtering after tag checkout
3. Remove Woo-specific unit tests
In unit tests of
example
module we had a set of Woo-specific unit tests, that requiredplugin:woocommerce
module to run and are not needed in scope of WordPress-Android project. I identified them and removed with:Review
There's not much to review in this specific PR. The final result will be possible to review in the integration PR.
You can verify that the last commit in this PR is the same as the commit from 2.99.0 release of FluxC (link). The same in a sense of content/message - hashes will be different as we rewrote history.