Skip to main content

Test it out

Let's crash you app. Enable crash reporting and paste the line below in the onCreate method in one of your activities. We'll crash the app on a button tap by accessing the array with the out of bounds index.

Launch you app after the crash, add a sentence or two if you want to and submit the report. Your report will be visible on the Shake dashboard in a few minutes.

public class MainActivity : Activity {
override fun onCreate(savedInstanceState: Bundle?) {
val buttonCrash: Button = findViewById(
buttonCrash.setOnClickListener {
val array = arrayOf(1, 2, 3)
val result = array[5]