Ticker

6/recent/ticker-posts

Android Studio Test Preparation 3

android-studio-test-prepration-3

Android Studio Test Preparation 3


Q # 1) What is Android?


Answer: Android is an open source operating system and is very popular on Smartphones and tablets.


This application is based on the Linux Kernel. Using the Android operating system, the developer performs tasks or programs that can perform basic tasks as well as advanced types of tasks on the Smartphone.


Q # 2) What is the Android SDK?


Answer: To improve the mobile app, Android developers need some tools and this requirement is met by the "Android SDK" which is a set of tools used to develop or write applications.


It has a Graphic User Interface that mimics the Android environment. This emulator works like a real mobile device where engineers write their code and then delete the error / check the same code to see if something is wrong.


Q # 3) What is the difference between a mobile performance test and a mobile test?


Answer: Mobile app testing is a test of apps on a device that focuses on the functions and features of the app.


Also Mobile Test is a real mobile app test and focuses on mobile features such as Call, SMS, Contacts, Media Player, built-in browsers, etc.


Q # 4) Name the languages ​​that support Android development.


Answer: Java is the language most widely used for Android development. It also supports C / C ++ and when used with the Android SDK, it also improves performance speed.


Q # 5) What are the benefits of the Android App?


Answer: It is open source and independent of the platform. It supports various technologies such as Bluetooth, Wi-Fi, etc.


Q # 6) Briefly describe Android Architecture.


Answer: Android architecture is in the form of software stack items.


The diagram below describes the various layers in the Android architecture.


Linux Kernel: Linux Kernel is located at the bottom of the software stack and is the basis for Android architecture. Using the Linux kernel, Android provides connectivity among other layers of software. It helps to improve drivers such as keypad, display, device-making sound, etc.

Hardware Abstraction Layer (HAL): HAL provides a interface between device drivers and API framework. It has library modules specific to the hardware component.

Android Running Time: The Linux kernel provides a multi-tasking environment so that multiple processes make each process run according to its Android Runtime (ART) model. Android has time-appropriate libraries such as Dalvik VM libraries, Java Interoperability libraries, Android libraries, and C / C ++ libraries.

Framework (Java API Framework): All Android functions are available via API. It has many services such as Task Manager, App Manager, Notification Manager, etc., which create the environment in which the Android app works.

Applications: The Android app is top layer and all kinds of built-in apps like SMS, Browsers, Contacts, etc. are included in this top layer. Includes third-party applications installed by the user such as Games, etc.


Q # 7) Define and define the Android Framework.


Answer: Android Frame is a set of APIs used by Android developers to write code for mobile applications. Contains modes and classes for programming code.


The Android framework includes a different set of tools for creating an image window, text field, buttons, etc. It also includes "Services" that the user encounters with "Services", which are applications running in the background. It is a package of various items such as targets, broadcast recipients, content providers, etc.


Q # 8) What are the requirements for a new Android project?


Answer: Whenever a new Android project is implemented, the following sections are required:


expression: Contains an XML file.

build /: Contains build / build.

src /: Contains code and resource files.

res /: Contains bitmap images, UI Strings and XML Layout i.e. all non-coding resources.

assets /: Contains a file that must be merged into an .apk file.


Q # 9) Provide key features of Android.


Answer: The main features of Android apps are:


Work

Objectives

Jobs

Content provider

A piece


Q # 10) Explain briefly - what does it mean for jobs?


Answer: Tasks are part of the mobile app that the user sees and interacts with.


For example, when you open a SMS application with many functions such as creating a new SMS, add a contact from the address book, write content to the SMS body, send an SMS to the selected contact, etc.


The employee keeps track of the following:


It keeps track of what the user wants now in the app.

It keeps track of previously used processes, so that the user can switch between continuous process and previous process.

It helps to kill processes to get the user back to his previous state

The work is performed as a sub-category of the Functional category as shown below:


The MyActivity community category expands Activity

{

}


Q # 11) What is meant by services?


Answer: The app is a part of Android that works in the background and is independent. It does not provide any user interface.


Although the services are running behind the scenes, the user can continue their work in various applications. Most of the time, users are unaware of the services running in the background. These services allow the system to execute the process without interrupting the user's ongoing operation.


The service is operated as a sub-category:


The MainService community section expands the Service

{

}


Q # 12) Briefly describe the Work Lifecycle.


Answer: When a user encounters an app and travels here and there, without an app, returns to the app, etc. Throughout this process work conditions also go through various stages of their life cycle.


There are seven different provinces such as - onCreate (), onStart (), onRestart (), onResume (), onPause (), onStop (), and onDestroy (). This is called a 'callback'. Android system requests these issues to know that the state has been changed.


When a user works on an app, then there are many functions involved in it such as Open, Close, Save, Delete, Post, etc.


Based on user action these functions are slightly cut off from the UI but these functions remain in the memory so that when the user returns the same function, the user is in the same state where they left off.


Q # 13) What Is the Purpose?


Answer: Android has an Intent section where the user has to navigate from one activity to another. The object displays notifications from the device to the user and the user can respond to the notification if needed.


Two types are given below:


Clear Objectives

Clear Objectives


Q # 14) Explain clear and unambiguous objectives.


Answer: The full objective calls for program items while the Explicit Objectives request the Task category.


Q # 15) What is the significance of setting permission for app development?


Answer: Once permissions have been set for app development, data and data are restricted to authorized users only.


If the code is stored without any restrictions or is accessible to anyone there is a chance that the code will be compromised leading to feature leaks.


Q # 16) What is the .apk extension for Android?


Answer: It is the default file format used by the Android Operating System. Application Package Kit (APK) is used for installation of mobile applications. .Apk contains an app file, a certificate, a manifest file, and some code.


APK files are archived files in zip format with the .apk extension.


Q # 17) What is the database used for the Android platform?


Answer: SQLite is a database used for the Android platform. It is an open-source, databaseless server.


Q # 18) What is ANR on Android?


Answer: ANR stands for Unanswered Request. It is a notification or pop-up displayed by the Android platform whenever the app performs too many tasks at a time and if it suddenly does not respond for a long time to the user's action.


Q # 19) Which chat boxes support the Android platform?


Answer: Android supports four types of chat boxes:


AlertDialog: It has 3 top buttons and sometimes AlertDialog includes checkboxes and Radio buttons to select an item.

ProgressDialog: Displays the progress bar or wheels.

TimePickerDialog: Using this dialog box, the user selects Time.

DatePickerDialog: Using this dialog box, the user selects a Date


Q # 20) What is ADB?


Answer: Android Debug Bridge (ADB) is a command line tool that executes Shell commands.


ADB is used for direct communication between emulator ports. Gives direct control of the communication between emulator conditions to the developer.


Q # 21) What is ActivityCreator?


Answer: ActivityCreator is the batch file and Shell script used to create the new Android project. It has now been replaced by "Create New Project" on Android SDK.


Q # 22) What is guidance?


Answer: Standing is a key feature in Smartphones these days. It has the ability to rotate the screen between horizontal or vertical mode.


Android supports two types of screen orientation as mentioned below:


Standby: When your device is aligned vertically.

Geographical: If your device is geographically aligned.

setOrientation () is a method you use to set screen alignment. HORIZONTAL and VERTICAL are two values ​​that can be set in the form of setOrientation (). Whenever there is a change in the display status i.e. from Horizontal to Vertical or vice versa onCreate () method function is dismissed.


Basically, when the direction of the Android mobile device is changed and the current function is destroyed and the same function is repeated in the new display guide. Android developers define the layout of the AndroidManifest.xml file.


Q # 23) What is AIDL?


Answer: For the Android platform, there are remote routes that use the routes from one application to another. Creating and using remote methods is the first step in defining a communication interface in AIDL.


AIDL stands for Android Interface Definition Language. Assists communication between client and service. It also transmits information through in-process communication.


Communication between processes, data is broken down into easily recognizable batches on the Android platform.


Q # 24) What types of data do AIDL support?


Answer: AIDL-supported data types are as follows:


String

List

Map

charSequence

Java data types such as INT, Long, Char, Boolean, etc.


Q # 25) Define the AndroidManifest.xml file and why do you need this?


Answer: All apps must have an AndroidManifest.xml file in the root directory. Contains information about your app and offers the same on the Android system.


Details include package name, Android features such as functionality, services, broadcast recipients, content providers, etc. All Android apps must have this information before using any app code.


The AndroidManifest.xml file performs the following functions:


It provides a name in the Java package and this name is a unique identifier for the application.

Defines a variety of app features including Task, Services, Content Providers, etc. Also, it describes classes that use these items.

It is responsible for the protection of the application and declares access to the protected part of the application.

It also announces the Android API to be used by the app.

Contains database information that is used and linked to the application.


Q # 26) What devices have you worked on?


Answer: There are many mobile devices available in the market with different applications.


Specifically, I have worked on Android, Windows, Symbian, iPhone, etc.


Q # 27) What tools are used to fix bugs on the Android platform?


Answer: To understand the cause of failure or the cause of any problem, correcting the error is important. On the Android platform Android Monitor.bat utility is used while on the iOS platform, the iPhone Configuration utility is used for debugging purposes.


There are various bug fix tools including: Android DDMS, Android Debug Bridge, iOS simulator, debug from Eclipse with ADT, remote debugging on Android with Chrome, etc.


Q # 28) What situation can only test on real devices but not on emulator?


Answer: Emulators are used to perform the same types of tests performed on real devices. Basically, emulators are used to replace real devices as sometimes real devices are not available for testing, the use of real mobile devices for testing purposes is sometimes more expensive.


But there are a few situations that cannot be tested using an emulator, this can only be tested using real devices. These conditions are interrupted by conditions such as message, phone interruption while using the app, low battery, Bluetooth, memory card upgrade and descent, etc.


Q # 29) Name the automated mobile tools available in the market.


Answer: There are a few automation testing tools available on the market but these are only used if the project requires it and if the application supports the default.


These are paid tools as well as free tools, which is why analysis needs to be done within the project team and the right mobile automation tool needs to be selected. Silk Mobile, SeeTest, Ranorex is a paid automation tool while Appium, KIF, Robotium, Calabash are a few free tools.


Q # 30) How do you solve Android crashes most often?


Answer: Listed below are a few steps we can take to solve the crash problem:


Free memory space: There is only limited space available on mobile devices for mobile applications. To avoid crashes or memory-related issues, you must first check the memory space.

Clear app data usage: You can clear app data using Application Manager under “Settings”. This will clear the cache memory and allow some free space to install another app or upgrade your current app.

Memory Management: Some applications work perfectly on one type of mobile device but the same application may not work on another type of device such as on those devices processing capacity, memory management, and CPU speed are different. For any app to work properly on any type of mobile device, you must manage the memory on the device.

Compatibility problem: It is always impossible to check mobile apps on all mobile devices, browsers, operating systems, etc. So you need to test your mobile app on as many mobile devices as possible to avoid any compatibility issues.


Q # 31) How do you detect memory leaks in a mobile app on the Android platform?


Answer: Android Studio uses Android Device Manager (ADM), this ADM is used to detect memory leaks on the Android platform.


When you open ADM in Android Studio and then to the left of ADM, you will find your device or emulator where the bulk icon will be displayed. If you use any mobile app you will see the bulk size, memory analysis and other statistics displayed in it.


Q # 32) What is DDMS?


Answer: Android Studio has DDMS debugging tools eg Dalvik Debug Monitor Server.


It has many debugging features that include:


Port transfer services.

Screen capture on device.

Details for Thread and Heap.

Incoming call and SMS spoofing.

Logcat

Radio state details.

Clicks for location data.

DDMS integrated with Android studio. To launch DDMS, you need to open Android Device Monitor (ADM) first and then click the DDMS menu button. Once the DDMS is launched, on the left side a list of connected devices is displayed along with the processes that apply to each device.


With the help of DDMS, you can fix errors on real devices and emulators.


Q # 33) What are the various data storage options available on the Android platform?


Answer: The Android platform offers many data storage options. These options should be used in accordance with a requirement such as whether the data is secure and used only with permission or is publicly accessible.


Below is a list of data storage options on the Android platform:


Shared Sharing: Saves data to XML files. It is an easy way to keep private information paired with a key value.

SQLite: Maintains systematic data in a private database.

Internal Storage: Storage data on device file system and another application cannot read this data.

External Storage: Data is stored in the file system but is available for all applications on the device


Q # 34) Explain Sensors on Android.


Answer: Android-enabled devices have built-in sensors that measure posture, movement, and other conditions.


These sensors provide details with high accuracy, which will help monitor the position and movement of the device. Some sensors are based on hardware and a few are designed for software.


There are three categories of sensors as mentioned below:


Motion Sensors: These sensors measure rotational speed and acceleration and include gravity sensors, rotating vector sensors, accelerometers, etc.

Natural Sensors: Measures air temperature, pressure, humidity, etc.

Positive Sensors: Means the physical condition of the device and includes directional sensors and magnetometers.

There are four types of Java classes as shown below:


Sensor Manager

Sensor

Sensor

SenorEventListener


The Conclusion

Almost all the important questions and answers for Android are covered here in this article. I hope this would be very helpful to you.


I'm sure you can break any Android conversation successfully with in-depth information on all of these questions.


I hope you are ready to be interviewed !! I wish you all the best !!


Related Topics

Android Studio Test Preparation 1



Post a Comment

0 Comments