Skip to content

Instantly share code, notes, and snippets.

View esmasui's full-sized avatar

Sosuke Masui esmasui

View GitHub Profile
this$0: Lcom/uphyca/galette/GAletteInstrumentationTest$NestedTestClass;
this$1: Lcom/uphyca/galette/GAletteInstrumentationTest$NestedNestedTestClass$InnerClass;
//Support inner classes
findViewById(R.id.button).setOnClickListener(new View.OnClickListener() {
@Override
@SendEvent(category = "button", action = "click")
public void onClick(View v) {
onButtonClicked();
}
});
@esmasui
esmasui / gist:7159dd73a08cab1d9eda
Created June 5, 2014 08:05
GoA buildToolsVersion 19.1
//def runtimeJars = plugins.findPlugin(com.android.build.gradle.AppPlugin).runtimeJars
def runtimeJars = plugins.findPlugin(com.android.build.gradle.AppPlugin).bootClasspath
E/SQLiteLog(14234): (1) ambiguous column name: conversation_id
D/AndroidRuntime(14234): Shutting down VM
E/AndroidRuntime(14234): FATAL EXCEPTION: IntentService[ScribeService]
E/AndroidRuntime(14234): Process: com.twitter.android, PID: 14234
E/AndroidRuntime(14234): android.database.sqlite.SQLiteException: ambiguous column name: conversation_id (code 1): , while compiling: CREATE VIEW dm_inbox AS SELECT conversations.conversation_id AS conversation_id,conversations.type AS type,conversations.title AS title,conversations.is_muted AS is_muted,conversations.last_readable_event_id>conversations.last_read_event_id AS is_unread,conversation_entries._id AS _id,conversation_entries.entry_id AS entry_id,conversation_entries.data AS data,conversation_entries.entry_type AS entry_type,conversation_entries.created AS created,most_recent_user.user_id AS user_id,most_recent_user.name AS s_name,most_recent_user.username AS s_username,most_recent_user.image_url AS s_profile_image_url,count(distinct(conversation_participants.u
language: java
jdk: oraclejdk7
before_install:
- export TERM=dumb
- sudo apt-get install -qq libstdc++6:i386 lib32z1
- export COMPONENTS=build-tools-19.0.3,build-tools-19.1.0,android-19,extra-android-m2repository
- curl -L https://raw.github.com/embarkmobile/android-sdk-installer/version-1/android-sdk-installer | bash /dev/stdin --install=$COMPONENTS
- source ~/.android-sdk-installer/env
14:04:43.730: Label add tap
14:04:44.237: OK - View with monkeyID CustometPreviewActivity, Navigate up is being clipped.
14:04:44.242: TextArea "name textfield" enterText <name>
14:04:44.745: TextArea "mail textfield" enterText <mail>
14:04:45.251: OK - Label with monkeyID preview is being clipped.
14:04:45.257: ButtonSelector "gender segmentedcontrol" Select <gender>
14:04:48.002: ERROR: Unable to find Radio Button '<gender>'
14:04:48.047: Completed Script Playback - ERROR Unable to find Radio Button '<gender>'
InputStreamを開く方法
1. ファイルシステムAPI
InputStream in = new FileInputStream(new File("/opt/foo/bar/mybatis-config.xml"));
2.1 リソースAPI
@esmasui
esmasui / gist:7c68c4ece96ea2130aa5
Created October 23, 2014 04:54
GA verbose, dry run
GoogleAnalytics ga = GoogleAnalytics.getInstance(context);
ga.setDryRun(true);
ga.getLogger().setLogLevel(Logger.LogLevel.VERBOSE);
@esmasui
esmasui / ExampleActivity.java
Last active August 29, 2015 14:20
AndroidのInstanceStateの保存・復元をアノテーションでやる再発明
/*
* Copyright (C) 2015 uPhyca Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@esmasui
esmasui / gist:6a98e2a2cb76dbdd6b9a
Created May 8, 2015 08:58
MoreObjects.toStringHelper (Guava)
public java.lang.String toString() {
return com.google.common.base.MoreObjects.toStringHelper(this)
#foreach ($member in $members)
.add("$member.name", $member.accessor)
#end
.toString();
}