Unclear Behaviour (UCB)

ECn Categories > Unclear Behaviour (UCB)

The app can have different or unexpected behaviors for a particular scenario and it is not clear why (from the user point of view).

Amount of Issues App List
11 (A1) QKSMS, (A2) Wire, (A7) AnntenaPod, (A8) iFixit, (A11) Mozilla Stumbler, (A40) Openshop.io 1.0, (A41) Glucosio,

Examples

iFixit

Category: Books and reference books
v 2.9.2
Scenario: To create a new guide without connection to internet

The following code snippets show the classes and files that are involved in the generation of the previuos issue.

App/src/com/dozuki/ifixit/ui/guide/create/StepEditActivity.java

public void onClick(View v) {

App/src/com/dozuki/ifixit/ui/guide/create/StepEditActivity.java

    case R.id.step_edit_save:
        label = "step_edit_save_step";
783.    save(mPagePosition);
        break;

App/src/com/dozuki/ifixit/ui/guide/create/StepEditActivity.java

    protected void save(int savePosition) {
      if (mGuide.isNewGuide()) {
1061.    createGuide();
      } else {
         saveStep(savePosition);
      }
    }

App/src/com/dozuki/ifixit/ui/guide/create/StepEditActivity.java

    private void createGuide() {

App/src/com/dozuki/ifixit/ui/guide/create/StepEditActivity.java

        // Create and show the dialog.
1085.   DialogFragment newFragment = NewGuideDialogFragment.newInstance(mGuide);
        newFragment.show(ft, "dialog");
    }

App/src/com/dozuki/ifixit/ui/guide/create/NewGuideDialogFragment.java

    public View onCreateView(LayoutInflater inflater, ViewGroup container,

App/src/com/dozuki/ifixit/ui/guide/create/NewGuideDialogFragment.java

     // Create an ArrayAdapter using the string array and a default spinner layout
     ArrayAdapter<String> adapter = new ArrayAdapter<String>(getActivity(), android.R.layout.simple_spinner_item,
114. App.get().getSite().getGuideTypesArray());

App/src/com/dozuki/ifixit/model/dozuki/Site.java

    public String[] getGuideTypesArray() {
101.    String[] typesArr = new String[mGuideTypes.size()];

        return getGuideTypes().toArray(typesArr);
    }

App/src/com/dozuki/ifixit/util/JSONHelper.java

    Iterator<?> keys = types.keys();
    while (keys.hasNext()) {
       String key = (String) keys.next();
       if (types.get(key) instanceof JSONObject) {
          site.mGuideTypes.add(parseGuideType(key, (JSONObject)types.get(key)));
       }
    }