Reputation: 1859
In an app I am debugging, In a content provider that's exported=true
, I have the following method:
public int myMethod(Uri uri, String name) {
return name.length;
}
I would like to test it via ADB. I'm not sure how to call it properly with the arguments.
adb shell content call --uri content://my_provider_url/ --method myMethod --arg Hello --arg2 Adam
I've also tried:
adb shell content call --uri content://my_provider_url/ --extra "URI:s:Hello" --extra "NAME:s:Adam"
Didn't work either - I keep getting Result:Null
I wish I could just add bindings - but the code isn't mine. How can I test this provider properly using adb (or a similar tool)?
Upvotes: 2
Views: 945