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

fix(tests): update canOpenURL test #14176

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/Resources/ti.platform.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -308,8 +308,8 @@ describe('Titanium.Platform', () => {
should(Ti.Platform.canOpenURL).be.a.Function();
});

it('returns true for typical http URL', () => {
should(Ti.Platform.canOpenURL('http://www.google.com/')).be.true();
it('returns true for typical https URL', () => {
should(Ti.Platform.canOpenURL('https://www.google.com/')).be.true();
});

it('returns true for app-sepcific URI scheme', () => {
Expand Down
17 changes: 17 additions & 0 deletions tests/platform/android/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,21 @@
<application>
<meta-data android:name="metatadata1" android:value="Metadata 1"/>
</application>
<queries>
<!-- Allows "http://" and "https://" web URLs. -->
<intent>
<action android:name="android.intent.action.VIEW"/>
<data android:scheme="https"/>
</intent>
<!-- Allows "mailto:" URLs to an e-mail app. -->
<intent>
<action android:name="android.intent.action.VIEW"/>
<data android:scheme="mailto"/>
</intent>
<!-- Allows file URLs to local image files. -->
<intent>
<action android:name="android.intent.action.VIEW"/>
<data android:mimeType="image/*"/>
</intent>
</queries>
</manifest>
Loading