Skip to content

Commit ede514c

Browse files
committed
Add support for API 15-19 system images.
1 parent 4a94905 commit ede514c

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

.github/workflows/workflow.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
timeout-minutes: 10
1414
strategy:
1515
matrix:
16-
api-level: [21, 23, 29]
16+
api-level: [16, 21, 23, 29]
1717
steps:
1818
- name: checkout
1919
uses: actions/checkout@v2
@@ -37,7 +37,7 @@ jobs:
3737
uses: ./
3838
with:
3939
api-level: ${{ matrix.api-level }}
40-
target: google_apis
40+
target: default
4141
arch: x86
4242
profile: Nexus 6
4343
emulator-options: -no-window -gpu swiftshader_indirect -no-snapshot -noaudio -no-boot-anim -camera-back none

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,9 @@ jobs:
6969

7070
| | **Required** | **Default** | **Description** |
7171
|----------------------|--------------|-------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
72-
| `api-level` | Required | N/A | API level of the platform system image - e.g. 23 for Android Marshmallow, 29 for Android 10. **Minimum API level supported is 21**. |
72+
| `api-level` | Required | N/A | API level of the platform system image - e.g. 23 for Android Marshmallow, 29 for Android 10. **Minimum API level supported is 15**. |
7373
| `target` | Optional | `default` | Target of the system image - `default` or `google_apis`. |
74-
| `arch` | Optional | `x86` | CPU architecture of the system image - `x86` or `x86_64`. |
74+
| `arch` | Optional | `x86` | CPU architecture of the system image - `x86` or `x86_64`. Note that `x86_64` image is only available for API 21+. |
7575
| `profile` | Optional | N/A | Hardware profile used for creating the AVD - e.g. `Nexus 6`. For a list of all profiles available, run `$ANDROID_HOME/tools/bin/avdmanager list` and refer to the results under "Available Android Virtual Devices". |
7676
| `emulator-options` | Optional | See below | Command-line options used when launching the emulator (replacing all default options) - e.g. `-no-window -no-snapshot -camera-back emulated`. |
7777
| `disable-animations` | Optional | `true` | Whether to disable animations - `true` or `false`. |

__tests__/input-validator.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ describe('api-level validator tests', () => {
1717

1818
it('Throws if api-level is lower than min API supported', () => {
1919
const func = () => {
20-
validator.checkApiLevel('20');
20+
validator.checkApiLevel('14');
2121
};
2222
expect(func).toThrowError(`Minimum API level supported is ${validator.MIN_API_LEVEL}.`);
2323
});
2424

2525
it('Validates successfully with valid api-level', () => {
2626
const func1 = () => {
27-
validator.checkApiLevel('21');
27+
validator.checkApiLevel('15');
2828
};
2929
expect(func1).not.toThrow();
3030

lib/input-validator.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
"use strict";
22
Object.defineProperty(exports, "__esModule", { value: true });
3-
exports.MIN_API_LEVEL = 21;
3+
exports.MIN_API_LEVEL = 15;
44
exports.VALID_TARGETS = ['default', 'google_apis'];
55
exports.VALID_ARCHS = ['x86', 'x86_64'];
66
function checkApiLevel(apiLevel) {

src/input-validator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export const MIN_API_LEVEL = 21;
1+
export const MIN_API_LEVEL = 15;
22
export const VALID_TARGETS: Array<string> = ['default', 'google_apis'];
33
export const VALID_ARCHS: Array<string> = ['x86', 'x86_64'];
44

0 commit comments

Comments
 (0)