Summary of the invention
Technical scheme provided by the invention is as follows:
A kind of test application provided by the invention runs the method for frame per second, comprising: step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; The testing scheme of step S50 corresponding to the application program each to be measured arranged, tests the operation frame per second of each application program to be measured.
Another kind of test application provided by the invention runs the method for frame per second, comprising: step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The testing scheme of step S50 corresponding to the application program each to be measured arranged, tests the operation frame per second of each application program to be measured.
Further, described step S40 also comprises: the test command corresponding to each application program to be measured of step S41 generates multistage test subcommand, every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured.
Another test application provided by the invention runs the method for frame per second, comprising: step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The testing scheme of step S50 corresponding to the application program each to be measured arranged, tests the operation frame per second of each application program to be measured; Step S60 generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains.
Further, described step S60 also comprises: step S61 is according to the application program multiple to be measured obtained, and generate the log file corresponding with each application program to be measured, each log file real time record tests the operation frame per second that an application program to be measured obtains.
Further, described step S61 also comprises: the log file corresponding to each application program to be measured of step S62 generates multiple record son file, the operation frame per second that each record son file real time record application program to be measured obtains under a kind of test frequency.
Another test application provided by the invention runs the method for frame per second, comprising: step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The testing scheme of step S50 corresponding to the application program each to be measured arranged, tests the operation frame per second of each application program to be measured; The operation frame per second that step S70 obtains according to each application process to be measured of test, judges whether the operation frame per second of this application process exceedes pre-set threshold value; If the operation frame per second of this application process of step S71 is within pre-set threshold value, then obtain the analysis result of this application program operational excellence; If the operation frame per second of this application process of step S72 exceedes pre-set threshold value, then obtain the suggestion that this application program needs to optimize.
A kind of test application provided by the invention runs the mobile terminal of frame per second, comprising: acquisition module, and this acquisition module resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Module is set, this arranges the application program multiple to be measured that module receives the output of described acquisition module, arrange in module described the testing scheme arranged corresponding to each application program to be measured, this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Intelligent test module, this intelligent test module receives the described testing scheme corresponding to application program each to be measured arranging module and export, and tests the operation frame per second of each application program to be measured.
Further, this mobile terminal also comprises: protocol generation module, this protocol generation module receives the application program multiple to be measured that described acquisition module exports, described protocol generation module also receives the described testing scheme corresponding to application program each to be measured arranging module and export, and generates test configurations agreement; Order generation module, this order generation module receives the test configurations agreement that described protocol generation module exports, resolve this test configurations agreement, generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order.
Further, this mobile terminal also comprises: file generating module, the operation frame per second that the application program multiple to be measured that this file generating module receives the output of described intelligent test module obtains, generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains.
Compared with prior art, test application provided by the invention runs the method for frame per second, by choosing multiple application program to be measured and arranging the testing scheme of each application program to be measured, each application program to be measured is tested accordingly, achieve frequency conversion test application, this method of testing the is had advantage such as testing efficiency is high, applicability is wide and dirigibility is strong.
This method of testing generates test subcommand after also passing through to resolve test configurations agreement, avoids, in the process of test application program operation to be measured frame per second, entanglement occurs, enhance the reliability of the course of work of the present invention.
The operation frame per second that each application program to be measured of this method of testing real time record test obtains, generate log file, check its test process at any time for user or tester, facilitate user or tester's Timeliness coverage application program to be measured produced problem in operational process.
This method of testing judges the operation frame per second that test application program to be measured obtains, and according to judged result, provides related advisory, so that user uses application program better, meets the experience requirements of user better.
Embodiment
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, contrast accompanying drawing is illustrated the specific embodiment of the present invention below.Apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings, and obtain other embodiment.
For making simplified form, only schematically show part related to the present invention in each figure, they do not represent its practical structures as product.In addition, be convenient to make simplified form understand, there are the parts of identical structure or function in some figure, only schematically depict one of them, or only marked one of them.In this article, " one " not only represents " only this ", also can represent the situation of " more than one ".
Fig. 1 is the schematic flow sheet that a kind of test application of the present invention runs the method for frame per second.As shown in Figure 1, according to one embodiment of present invention, a kind of test application runs the method for frame per second, comprising: preferred, also comprises step S01 display installation application program (the parsing bag title corresponding to application program) on mobile terminals; Step S10 resolves the operation of user, obtains multiple (one, two, three, six the etc.) application program to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it; Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time; The testing scheme of step S50 corresponding to the application program each to be measured arranged, tests the operation frame per second of each application program to be measured.
Fig. 2 is the schematic flow sheet that the another kind of test application of the present invention runs the method for frame per second.As shown in Figure 2, according to another embodiment of the invention, test application runs a method for frame per second, comprising: preferred, also comprises step S01 display installation application program (the parsing bag title corresponding to application program) on mobile terminals;
Step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Described test configurations agreement can be a total agreement of test configurations, and the total agreement of this test configurations comprises multiple application program to be measured, testing scheme related content corresponding to each application program to be measured; Described test configurations agreement also can comprise an application program to be measured, this testing scheme related content corresponding to application program to be measured; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Preferably, the test command also comprised corresponding to each application program to be measured of step S41 generates multistage test subcommand, and every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured; The test frequency of such as talk application program is that the test subcommand of per second/1 time is as follows: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, without the need to variation.The test subcommand of the test frequency of talk application program to be the test subcommand of every 500 milliseconds/1 time, every 100 milliseconds/1 time can be with reference to above-mentioned test frequency per second/1 time;
The testing scheme of step S50 corresponding to the application program each to be measured arranged, runs application program to be measured, performs test subcommand, tests the operation frame per second of each application program to be measured.
Fig. 3 is the schematic flow sheet that another test application of the present invention runs the method for frame per second.As shown in Figure 3, according to still a further embodiment, test application runs a method for frame per second, comprising: preferred, also comprises step S01 display installation application program (the parsing bag title corresponding to application program) on mobile terminals;
Step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Described test configurations agreement can be a total agreement of test configurations, and the total agreement of this test configurations comprises multiple application program to be measured, testing scheme related content corresponding to each application program to be measured; Described test configurations agreement also can comprise an application program to be measured, this testing scheme related content corresponding to application program to be measured; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Preferably, the test command also comprised corresponding to each application program to be measured of step S41 generates multistage test subcommand, and every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured; The test frequency of such as talk application program is that the test subcommand of per second/1 time is as follows: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, without the need to variation.The test subcommand of the test frequency of talk application program to be the test subcommand of every 500 milliseconds/1 time, every 100 milliseconds/1 time can be with reference to above-mentioned test frequency per second/1 time;
The testing scheme of step S50 corresponding to the application program each to be measured arranged, runs application program to be measured, performs test subcommand, tests the operation frame per second of each application program to be measured; Step S60 generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains.
Fig. 4 is the schematic flow sheet that a kind of test application of the present invention runs the method for frame per second.As shown in Figure 4, according to still another embodiment of the invention, test application runs a method for frame per second, comprising: preferred, also comprises step S01 display installation application program (the parsing bag title corresponding to application program) on mobile terminals;
Step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Described test configurations agreement can be a total agreement of test configurations, and the total agreement of this test configurations comprises multiple application program to be measured, testing scheme related content corresponding to each application program to be measured; Described test configurations agreement also can comprise an application program to be measured, this testing scheme related content corresponding to application program to be measured; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Preferably, the test command also comprised corresponding to each application program to be measured of step S41 generates multistage test subcommand, and every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured; The test frequency of such as talk application program is that the test subcommand of per second/1 time is as follows: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, without the need to variation.The test subcommand of the test frequency of talk application program to be the test subcommand of every 500 milliseconds/1 time, every 100 milliseconds/1 time can be with reference to above-mentioned test frequency per second/1 time;
The testing scheme of step S50 corresponding to the application program each to be measured arranged, runs application program to be measured, performs test subcommand, tests the operation frame per second of each application program to be measured; Step S60 generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains;
Step S61 is according to the application program multiple to be measured obtained, and generate the log file corresponding with each application program to be measured, each log file real time record tests the operation frame per second that an application program to be measured obtains; Log file can be named according to the parsing bag title of each application program; By the dumpsysgfxinfo interface interchange of android, and be redirected in designated recorder file, in Profiledatainms, just can obtain real time data; Log file corresponding to each application program to be measured of step S62 generates multiple record son file, the operation frame per second that each record son file real time record application program to be measured obtains under a kind of test frequency.
Fig. 5 is the schematic flow sheet that a kind of test application of the present invention runs the method for frame per second.As shown in Figure 5, according to another embodiment again of the present invention, test application runs a method for frame per second, comprising: preferred, also comprises step S01 display installation application program (the parsing bag title corresponding to application program) on mobile terminals;
Step S10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Step S20 arranges the testing scheme corresponding to each application program to be measured, and this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
The testing scheme of step S30 corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Described test configurations agreement can be a total agreement of test configurations, and the total agreement of this test configurations comprises multiple application program to be measured, testing scheme related content corresponding to each application program to be measured; Described test configurations agreement also can comprise an application program to be measured, this testing scheme related content corresponding to application program to be measured; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Step S40 resolves the test configurations agreement generated, and generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Preferably, the test command also comprised corresponding to each application program to be measured of step S41 generates multistage test subcommand, and every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured; The test frequency of such as talk application program is that the test subcommand of per second/1 time is as follows: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, without the need to variation.The test subcommand of the test frequency of talk application program to be the test subcommand of every 500 milliseconds/1 time, every 100 milliseconds/1 time can be with reference to above-mentioned test frequency per second/1 time;
The testing scheme of step S50 corresponding to the application program each to be measured arranged, runs application program to be measured, tests the operation frame per second of each application program to be measured;
The operation frame per second that step S70 obtains according to each application process to be measured of test, judges whether the operation frame per second of this application process exceedes pre-set threshold value; Pre-set threshold value be frame per second at about 16ms, the words lower than 1 second 60 frame be need be optimized; If the operation frame per second of this application process of step S71 exceedes pre-set threshold value, then obtain the analysis result of this application program operational excellence; If the operation frame per second of this application process of step S72 is lower than pre-set threshold value, then obtain the suggestion that this application program needs to optimize.
According to one embodiment of present invention, a kind of test application runs the mobile terminal of frame per second, comprising: preferred, also comprises display module, and application program (the parsing bag title corresponding to application program) is on mobile terminals installed in display; Acquisition module 10, this acquisition module 10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it; Module 20 is set, this arranges the application program multiple to be measured that module 20 receives the output of described acquisition module 10, arrange in module 20 described the testing scheme arranged corresponding to each application program to be measured, this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time; Intelligent test module 50, this intelligent test module 50 receives the described testing scheme corresponding to application program each to be measured arranging module 20 and export, and tests the operation frame per second of each application program to be measured.
Fig. 6 is the composition structural representation of a kind of mobile terminal of the present invention.As shown in Figure 6, according to another embodiment of the invention, a kind of test application runs the mobile terminal of frame per second, comprising: preferred, also comprise display module, application program (the parsing bag title corresponding to application program) is on mobile terminals installed in display;
Acquisition module 10, this acquisition module 10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Module 20 is set, this arranges the application program multiple to be measured that module 20 receives the output of described acquisition module 10, arrange in module 20 described the testing scheme arranged corresponding to each application program to be measured, this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
Protocol generation module 30, this protocol generation module 30 receives the application program multiple to be measured that described acquisition module 10 exports, described protocol generation module 30 also receives the described testing scheme corresponding to application program each to be measured arranging module 20 and export, and generates test configurations agreement; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Order generation module 40, this order generation module 40 receives the test configurations agreement that described protocol generation module 30 exports, resolve this test configurations agreement, generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Intelligent test module 50, this intelligent test module 50 receives the described testing scheme corresponding to application program each to be measured arranging module 20 and export, and tests the operation frame per second of each application program to be measured; File generating module 60, the operation frame per second that the application program multiple to be measured that this file generating module 60 receives the output of described intelligent test module 50 obtains, generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains.
Fig. 7 is the composition structural representation of the another kind of mobile terminal of the present invention.As shown in Figure 7, according to still another embodiment of the invention, a kind of test application runs the mobile terminal of frame per second, comprising: preferred, also comprise display module, application program (the parsing bag title corresponding to application program) is on mobile terminals installed in display;
Acquisition module 10, this acquisition module 10 resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Module 20 is set, this arranges the application program multiple to be measured that module 20 receives the output of described acquisition module 10, arrange in module 20 described the testing scheme arranged corresponding to each application program to be measured, this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
Protocol generation module 30, this protocol generation module 30 receives the application program multiple to be measured that described acquisition module 10 exports, described protocol generation module 30 also receives the described testing scheme corresponding to application program each to be measured arranging module 20 and export, and generates test configurations agreement; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Order generation module 40, this order generation module 40 receives the test configurations agreement that described protocol generation module 30 exports, resolve this test configurations agreement, generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Intelligent test module 50, this intelligent test module 50 receives the described testing scheme corresponding to application program each to be measured arranging module 20 and export, and tests the operation frame per second of each application program to be measured;
Judge module 70, the operation frame per second that each application process to be measured of test that this judge module 70 receives the output of described intelligent test module 50 obtains, judges that the operation frame per second of this application process is within pre-set threshold value; Pre-set threshold value be frame per second at about 16ms, the words lower than 1 second 60 frame be need be optimized; Analysis module 80, this analysis module 80 receives the operation frame per second of this application process that described judge module 70 exports within pre-set threshold value, draws the analysis result of this application program operational excellence; Suggestion module 90, the operation frame per second that this suggestion module 90 receives this application process that described judge module 70 exports exceedes pre-set threshold value, show that this application program needs the suggestion optimized.
According to still a further embodiment, a kind of test application runs the method for frame per second, comprising: preferred, is also included in display module the application program (the parsing bag title corresponding to application program) showing and install on mobile terminals;
Acquisition module 10, resolves the operation of user, obtains the application program multiple to be measured chosen on mobile terminals; Obtain the application program multiple to be measured chosen on mobile terminals to refer to: obtain the parsing bag title corresponding to application program multiple to be measured chosen on mobile terminals; Such as: in mobile terminal, the parsing bag name of talk application program is called com.feixun.phone, this parsing bag title calls the operation of call module by it;
Arranging in module 20 testing scheme arranged corresponding to each application program to be measured, this testing scheme refers to: the multiple test frequency corresponding to each application program to be measured and the test duration corresponding to often kind of test frequency; Such as: the test T.T. arranging talk application program is 30 minutes, the test frequency of first 10 minute test duration is per second/1 time, the test frequency of middle 10 minute test duration is every 500 milliseconds/1 time, and the test frequency of latter 10 minute test duration is every 100 milliseconds/1 time;
Protocol generation module 30, according to the testing scheme corresponding to the application program multiple to be measured obtained, each application program to be measured, generates test configurations agreement; Described test configurations agreement can be a total agreement of test configurations, and the total agreement of this test configurations comprises multiple application program to be measured, testing scheme related content corresponding to each application program to be measured; Described test configurations agreement also can comprise an application program to be measured, this testing scheme related content corresponding to application program to be measured; Such as: the test configurations agreement of talk application program is com.feixun.phone10:1S, 10:0.5S, 10:0.1S;
Order generation module 40, resolve the test configurations agreement generated, generate the test command corresponding with each application program to be measured, the operation frame per second of an application program to be measured is tested in every BT(batch testing) order; The form of its test command is: fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein pacages, Intervals receive variable parameter;
Preferably, also comprise order generation module 40, test command corresponding to each application program to be measured is generated multistage test subcommand, every section of test subcommand, under a kind of test frequency corresponding to an application program to be measured, tests the operation frame per second of this application program to be measured; The test frequency of such as talk application program is that the test subcommand of per second/1 time is as follows: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, without the need to variation.The test subcommand of the test frequency of talk application program to be the test subcommand of every 500 milliseconds/1 time, every 100 milliseconds/1 time can be with reference to above-mentioned test frequency per second/1 time;
Intelligent test module 50, according to the testing scheme corresponding to the application program each to be measured arranged, runs application program to be measured, performs test subcommand, tests the operation frame per second of each application program to be measured;
File generating module 60, generates the log file of the operation frame per second that the multiple application program to be measured of real time record test obtains; File generating module 60, also according to the application program multiple to be measured obtained, generate the log file corresponding with each application program to be measured, each log file real time record tests the operation frame per second that an application program to be measured obtains; Log file can be named according to the parsing bag title of each application program; By the dumpsysgfxinfo interface interchange of android, and be redirected in designated recorder file, in Profiledatainms, just can obtain real time data; File generating module 60, generates multiple record son file by the log file corresponding to each application program to be measured, the operation frame per second that each record son file real time record application program to be measured obtains under a kind of test frequency;
Judge module 70, according to the operation frame per second that each application process to be measured of test obtains, judges whether the operation frame per second of this application process exceedes pre-set threshold value; Pre-set threshold value be frame per second at about 16ms, the words lower than 1 second 60 frame be need be optimized; Analysis module 80, if the operation frame per second of this application process exceedes pre-set threshold value, then obtains the analysis result of this application program operational excellence; Suggestion module 90, if the operation frame per second of this application process is lower than pre-set threshold value, then obtains the suggestion that this application program needs to optimize.
Fig. 8 is the composition structural representation of another mobile terminal of the present invention; Fig. 9 is the composition structural representation of front-end configuration device in the present invention; Figure 10 is the composition structural representation of operation controller in the present invention; Figure 11 is the composition structural representation of frame per second acquisition module in the present invention.As shown in Fig. 8, Fig. 9, Figure 10, Figure 11, according to one embodiment of present invention, test application runs a method for frame per second, comprising: front-end configuration device 100 (as shown in Figure 9), operation controller 200 (as shown in Figure 10) and frame per second acquisition module 300 (as shown in figure 11);
APP is selected, by the APP application in graphical interfaces method choice mobile terminal by APP resolver 101 in front-end configuration device 100; Obtain the method that APP resolves bag name: by code adbshellpmlistpackages>. config packages.txt obtain bag name relevant in mobile phone, and to show on graphical interfaces, select to user; Such as: user selects com.feixun.phone, these data converse the code packages name of module in mobile terminal, calls the operation of call module by it;
Operating scheme configuration 102, can input the time that this APP of user test is used; Such as: it is 30 minutes that this APP tests T.T., wherein, within first 10 minutes, be per second/1 time operation, centre 10 minutes is every 500 milliseconds/1 time, within last 10 minutes, is the configuration of every 100 milliseconds/1 time operation;
Generate configuration protocol (com.feixun.phone10:1S, 10:0.5S, 10:0.1S), by that analogy, when user have selected N number of Bao Minghou (com.feixun.camera15:1S, 12:0.5S, 15:0.1S) .... the operating scheme of the test pack that user selects and input all will be written in configuration;
Operation controller 200, receive operating scheme and configure 102 protocol contents, undertaken in decomposition write operation code by protocol resolver 201, fileWriter (" adbshellmonkey "+pacages+ "-s "+Seeds+ "--throttle "+Intervals+ "-v "+clicks); Wherein, fileWrite receives file processing scheme by one, and the content receiving file is in bracket below, and be the order of a string adb batch processing, wherein grey can be receive variable parameter;
Such as: the errorlevel generated by bag com.feixun.phone is adbshellmonkeycom.feixun.phone-s100Seeds--throttle1000-v 50000, wherein, com.feixun.phone is running package name, throttle1000 represents 1000 milliseconds, remaining-s100Seeds and-v50000 is default parameters, does not change;
3 sections of errorlevels will be resolved to according to above-mentioned this row configuration protocol of front-end configuration agreement (com.feixun.phone10:1S, 10:0.5S, 10:0.1S) to be run one by one by Monkey performer 202, namely open the errorlevel in 16;
Frame per second acquisition module 300, frame number during frame per second monitor 301 energy Real-Time Monitoring running of mobile terminal, and the function of energy recording real-time data; By the dumpsysgfxinfo interface interchange of android, and be redirected in designated recorder file, in Profiledatainms, just can obtain real time data; Frame per second should, at about 16ms, if 1 second 60 frame needs to be optimized, can be carried out presetting judgement process according to demand under normal circumstances; The log file of specifying can be named according to bag name;
Divide packet handing module 302, the operation of different frequency can be carried out in identical APP bag, in same bag name log file, the differentiation of different operating frequencies operations can be carried out;
Another APP bag name log file can be generated in different APP bag, carry out differentiation data with this; Last output test result.
A kind of test application that the present embodiment provides runs the method for frame per second, in main testing mobile terminal, each APP runs fluency, and by the pre-configured different travelling speed of front-end configuration device 100, carry out executable operations by operation controller 200, this real time operating data of acquisition frame rate.This method can understand different APP under different operating frequencies, and whether frame data exist exceptional value.Meanwhile, this method is the scheme of full-automatic testing frame number, has the efficient feature of operation, can also meet the combination of different operating frequency, have higher dirigibility.
It should be noted that above-described embodiment all can independent assortment as required.The above is only the preferred embodiment of the present invention; it should be pointed out that for those skilled in the art, under the premise without departing from the principles of the invention; can also make some improvements and modifications, these improvements and modifications also should be considered as protection scope of the present invention.