Skip to content

Commit

Permalink
Merge pull request #6854 from robolectric/piper_409490755
Browse files Browse the repository at this point in the history
Remove inaccessible Google issue tracker links
  • Loading branch information
hoisie committed Nov 17, 2021
2 parents a251f16 + 45724fa commit 52f0d7d
Show file tree
Hide file tree
Showing 11 changed files with 25 additions and 28 deletions.
Expand Up @@ -656,7 +656,7 @@ public boolean isNinePatch() {
// : mStart(0), mLength(0), mOffset(0), mFp(null), mFileName(null), mMap(null), mBuf(null)
{
// Register the Asset with the global list here after it is fully constructed and its
// vtable pointer points to this concrete type. b/31113965
// vtable pointer points to this concrete type.
registerAsset(this);
}

Expand All @@ -668,7 +668,7 @@ protected void finalize() {
close();

// Unregister the Asset from the global list here before it is destructed and while its vtable
// pointer still points to this concrete type. b/31113965
// pointer still points to this concrete type.
unregisterAsset(this);
}

Expand Down Expand Up @@ -1136,7 +1136,7 @@ public boolean isNinePatch() {
mFd = -1;

// Register the Asset with the global list here after it is fully constructed and its
// vtable pointer points to this concrete type. b/31113965
// vtable pointer points to this concrete type.
registerAsset(this);
}

Expand Down Expand Up @@ -1167,7 +1167,7 @@ protected void finalize() {
close();

// Unregister the Asset from the global list here before it is destructed and while its vtable
// pointer still points to this concrete type. b/31113965
// pointer still points to this concrete type.
unregisterAsset(this);
}

Expand Down
Expand Up @@ -166,7 +166,6 @@ Chunk Next() {
return new Chunk(this_chunk);
}

// TODO(b/111401637) remove this and have full resource file verification
// Returns false if there was an error. For legacy purposes.
boolean VerifyNextChunkNonFatal() {
if (len_ < ResChunk_header.SIZEOF) {
Expand Down
Expand Up @@ -239,7 +239,7 @@ static ImmutableMap<String, Long> guessDataOffsets(File zipFile, int length) {
while (true) {
// Instead of trusting numRecords, read until we find the
// end-of-central-directory signature. numRecords may wrap
// around with >64K entries (b/5455504).
// around with >64K entries.
int sig = readInt(buffer, offset);
if (sig == ENDSIG || sig == ENDSIG64) {
break;
Expand Down
Expand Up @@ -57,7 +57,8 @@ public boolean injectKeyEvent(KeyEvent event) throws InjectEventSecurityExceptio
return true;
}

// TODO(b/80130000): implementation copied from espresso's UIControllerImpl. Refactor code into common location
// TODO: implementation copied from espresso's UIControllerImpl. Refactor code into common
// location
@Override
public boolean injectString(String str) throws InjectEventSecurityException {
checkNotNull(str);
Expand All @@ -72,8 +73,7 @@ public boolean injectString(String str) throws InjectEventSecurityException {
boolean eventInjected = false;
KeyCharacterMap keyCharacterMap = getKeyCharacterMap();

// TODO(b/80130875): Investigate why not use (as suggested in javadoc of
// keyCharacterMap.getEvents):
// TODO: Investigate why not use (as suggested in javadoc of keyCharacterMap.getEvents):
// http://developer.android.com/reference/android/view/KeyEvent.html#KeyEvent(long,
// java.lang.String, int, int)
KeyEvent[] events = keyCharacterMap.getEvents(str.toCharArray());
Expand Down
Expand Up @@ -4,7 +4,6 @@
import static com.google.common.truth.Truth.assertThat;
import static com.google.common.util.concurrent.MoreExecutors.directExecutor;
import static org.junit.Assert.assertThrows;
import static org.junit.Assert.fail;
import static org.mockito.ArgumentMatchers.anyFloat;
import static org.mockito.ArgumentMatchers.anyInt;
import static org.mockito.Mockito.mock;
Expand Down Expand Up @@ -69,18 +68,16 @@ public void startBugreport_noPermission() throws Exception {
BugreportCallback callback = mock(BugreportCallback.class);
shadowBugreportManager.setHasPermission(false);

// TODO(b/179958637) switch to assertThrows once ThrowingRunnable no longer causes a test
// instantiation failure.
try {
shadowBugreportManager.startBugreport(
createWriteFile("bugreport"),
createWriteFile("screenshot"),
new BugreportParams(BugreportParams.BUGREPORT_MODE_FULL),
directExecutor(),
callback);
fail("Expected SecurityException");
} catch (SecurityException expected) {
}
assertThrows(
SecurityException.class,
() -> {
shadowBugreportManager.startBugreport(
createWriteFile("bugreport"),
createWriteFile("screenshot"),
new BugreportParams(BugreportParams.BUGREPORT_MODE_FULL),
directExecutor(),
callback);
});
shadowMainLooper().idle();

assertThat(shadowBugreportManager.isBugreportInProgress()).isFalse();
Expand Down
Expand Up @@ -204,7 +204,7 @@ public void postAndRemoveSyncBarrierToken() {
}

@Test
// TODO(b/74402484): enable once workaround is removed
// TODO(https://github.com/robolectric/robolectric/issues/6852): enable once workaround is removed
@Ignore
public void removeInvalidSyncBarrierToken() {
try {
Expand Down
Expand Up @@ -82,7 +82,7 @@ private static URL[] getClassPathUrls(ClassLoader classloader) {
return parseJavaClassPath();
}

// TODO(b/65488446): Use a public API once one is available.
// TODO(https://github.com/google/guava/issues/2956): Use a public API once one is available.
private static URL[] parseJavaClassPath() {
ImmutableList.Builder<URL> urls = ImmutableList.builder();
for (String entry : Splitter.on(PATH_SEPARATOR.value()).split(JAVA_CLASS_PATH.value())) {
Expand Down
Expand Up @@ -166,7 +166,8 @@ private static void dispatchMessage(Message msg) {
@Implementation
@HiddenApi
protected void removeSyncBarrier(int token) {
// TODO(b/74402484): workaround scheduler corruption of message queue
// TODO(https://github.com/robolectric/robolectric/issues/6852): workaround scheduler corruption
// of message queue
try {
reflector(MessageQueueReflector.class, realQueue).removeSyncBarrier(token);
} catch (IllegalStateException e) {
Expand Down
Expand Up @@ -89,7 +89,7 @@ public Parcelable.Creator<?> readParcelableCreator(ClassLoader loader) {
// classloader" behavior.
ClassLoader parcelableClassLoader = (loader == null ? getClass().getClassLoader() : loader);
// Avoid initializing the Parcelable class until we know it implements
// Parcelable and has the necessary CREATOR field. http://b/1171613.
// Parcelable and has the necessary CREATOR field.
Class<?> parcelableClass = Class.forName(name, false /* initialize */, parcelableClassLoader);
if (!Parcelable.class.isAssignableFrom(parcelableClass)) {
throw new BadParcelableException(
Expand Down
Expand Up @@ -15,6 +15,6 @@ public class ShadowSQLiteOpenHelper {
@Implementation(minSdk = O_MR1)
protected void setIdleConnectionTimeout(long idleConnectionTimeoutMs) {
// Calling the real one currently results in a Robolectric deadlock. Just ignore it.
// See b/78464547 .
// See https://github.com/robolectric/robolectric/issues/6853.
}
}
Expand Up @@ -918,7 +918,7 @@ public void setSignalStrength(SignalStrength signalStrength) {
/**
* Cribbed from {@link android.telephony.PhoneNumberUtils#isEmergencyNumberInternal}.
*
* <p>TODO(b/122324733) need better implementation
* <p>TODO: need better implementation
*/
@Implementation(minSdk = Build.VERSION_CODES.Q)
protected boolean isEmergencyNumber(String number) {
Expand Down

0 comments on commit 52f0d7d

Please sign in to comment.