B2G/QA/WebAPI Test Plan/Camera

< B2G‎ | QA‎ | WebAPI Test Plan
Revision as of 04:18, 24 August 2012 by Dclarke (talk | contribs) (Created page with "=B2G Screen Orientation API Test Plan= == Summary == {| class="fullwidth-table" |- | style="width:28%" | '''Lead''' | [mailto:dclarke@mozilla.com David Clarke] (irc: onecyren...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

B2G Screen Orientation API Test Plan

Summary

Lead David Clarke (irc: onecyrenus)
Contributors
API Description Camera API, used to get pictures, and put a preview screen on the page
API Developer Mounir Lamouri
API Project Page Screen Orientation
API Tracking Bugs bug 740997
API Status Delivered and ready for test

Scope

This test plan covers functional testing of the Camera API as delivered for Boot2Gecko. It does not attempt to cover performance, security, or other kinds of testing at this time.

Strategy

The ability to be able to test the camera api will cover three areas.

1) 3rd Party App 2) Browser 3) Camera App

API

Camera API is relatively simple, and is defined as part of the nsIDOMCameraManager idl.

nsIDOMCameraManager

The attributes that I would like to iterate on, or be able to test are the following.

Attributes

   readonly attribute jsval        previewSizes;
   readonly attribute jsval        pictureSizes;
   readonly attribute jsval        fileFormats;
   readonly attribute jsval        whiteBalanceModes;
   readonly attribute jsval        sceneModes;
   readonly attribute jsval        effects;
   readonly attribute jsval        flashModes;
   readonly attribute jsval        focusModes;
   readonly attribute long         maxFocusAreas;
   readonly attribute double       minExposureCompensation;
   readonly attribute double       maxExposureCompensation;
   readonly attribute double       stepExposureCompensation;
   readonly attribute long         maxMeteringAreas;
   readonly attribute jsval        zoomRatios;
   readonly attribute jsval        videoSizes;


Methods

  • void autoFocus(in nsICameraAutoFocusCallback onSuccess, [optional] in nsICameraErrorCallback onError);
  • void takePicture(in jsval aOptions, in nsICameraTakePictureCallback onSuccess, [optional] in nsICameraErrorCallback onError);
  • void startRecording(in jsval aOptions, in nsICameraStartRecordingCallback onSuccess, [optional] in nsICameraErrorCallback onError);
  • void stopRecording();
  • void getPreviewStream(in jsval aOptions, in nsICameraPreviewStreamCallback onSuccess, [optional] in nsICameraErrorCallback onError);

Basic Positive Tests

mochitest-plain

Sanity Tests

Basic Negative Tests

Test App Design

This page is based on the WebAPI Test Plan Template