mirror of
https://github.com/apache/cordova-android.git
synced 2026-04-23 00:00:09 +08:00
- General Code Refactor - Removed builder type argument from getBuilder API - Removed any reference of conditional statements around builder type - Remove plugin handler install and uninstall option flag android_studio - Remove --gradle flag references - Fixed plugin handler install and uninstall pathing issues - Added parseBuildOptions export so run can get build related options. - Use the nobuild flag option to control the run build. - Updated test spec to reflect the changes.
This commit is contained in:
@@ -38,16 +38,7 @@ describe('AndroidProject', () => {
|
||||
expect(project.projectDir).toBe(PROJECT_DIR);
|
||||
});
|
||||
|
||||
it('should set www folder correctly if not Android Studio project', () => {
|
||||
AndroidStudioSpy.isAndroidStudioProject.and.returnValue(false);
|
||||
|
||||
const project = new AndroidProject(PROJECT_DIR);
|
||||
expect(project.www).toBe(path.join(PROJECT_DIR, 'assets/www'));
|
||||
});
|
||||
|
||||
it('should set www folder correctly if it is an Android Studio project', () => {
|
||||
AndroidStudioSpy.isAndroidStudioProject.and.returnValue(true);
|
||||
|
||||
const project = new AndroidProject(PROJECT_DIR);
|
||||
expect(project.www).toBe(path.join(PROJECT_DIR, 'app/src/main/assets/www'));
|
||||
});
|
||||
@@ -108,19 +99,8 @@ describe('AndroidProject', () => {
|
||||
androidProject = new AndroidProject(PROJECT_DIR);
|
||||
});
|
||||
|
||||
it('should get the package name from the project root manifest', () => {
|
||||
AndroidStudioSpy.isAndroidStudioProject.and.returnValue(false);
|
||||
|
||||
it('should get the package name AndroidManifest', () => {
|
||||
androidProject.getPackageName();
|
||||
|
||||
expect(AndroidManifestSpy).toHaveBeenCalledWith(path.join(PROJECT_DIR, 'AndroidManifest.xml'));
|
||||
});
|
||||
|
||||
it('should get the package name from the Android Studio manifest', () => {
|
||||
AndroidStudioSpy.isAndroidStudioProject.and.returnValue(true);
|
||||
|
||||
androidProject.getPackageName();
|
||||
|
||||
expect(AndroidManifestSpy).toHaveBeenCalledWith(path.join(PROJECT_DIR, 'app/src/main/AndroidManifest.xml'));
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user