Search Results

Search found 654 results on 27 pages for 'coverage'.

Page 4/27 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • <100% Test coverage - best practices in selecting test areas

    - by Paul Nathan
    Suppose you're working on a project and the time/money budget does not allow 100% coverage of all code/paths. It then follows that some critical subset of your code needs to be tested. Clearly a 'gut-check' approach can be used to test the system, where intuition and manual analysis can produce some sort of test coverage that will be 'ok'. However, I'm presuming that there are best practices/approaches/processes that identify critical elements up to some threshold and let you focus your test elements on those blocks. For example, one popular process for identifying failures in manufacturing is Failure Mode and Effects Analysis. I'm looking for a process(es) to identify critical testing blocks in software.

    Read the article

  • Watch Google’s I/O 2012 Developer Conference Live (Online) Starting June 27

    - by Asian Angel
    Google’s annual I/O conference begins on Wednesday this week and will be filled with exciting sessions about Android, Chrome, Google+, and more. To help you keep up with all the fun we have the links you need so that you can tune in with live streaming! Photo courtesy of Google I/O website. The keynote for Day 1 will begin at 9:30 a.m. PDT (U.S. time) and the keynote for the second day will begin at 10:00 a.m. PDT (U.S. time), so make sure to mark it on your schedule! Visit the blog post linked below for more details about signing up for Extended Events, the I/O mobile app, the liveblogging gadget, and more. SPECIAL NOTE: The Google blog post linked below was slightly ambiguous and listed both of the I/O URLs we have shown here, so make sure to keep a watch on both… How to Banish Duplicate Photos with VisiPic How to Make Your Laptop Choose a Wired Connection Instead of Wireless HTG Explains: What Is Two-Factor Authentication and Should I Be Using It?

    Read the article

  • Catch Up on Your Reading

    - by [email protected]
    AutoVue 20.0 was a major release which included many new features and enhancements. We eagerly shared the news with members of the media, who in turn wrote about AutoVue enterprise visualization in various online articles. Here is a summary of the articles featuring AutoVue 20.0. Happy reading! Oracle Unveils AutoVue 20.0 Desktop Engineering; April 5, 2010 Oracle Upgrades Document Visualization Tool Managing Automation; April 5, 2010 Oracle's AutoVue 20.0 Enhances Visual Document Collaboration CMS Wire; April 6, 2010 Oracle Turns Attention to Project and Document Management Channel Insider; April 7, 2010 Oracle Unveils AutoVue 20.0 Database Trends and Applications; April 7, 2010

    Read the article

  • Why can't I get 100% code coverage on a method that calls a constructor of a generic type?

    - by Martin Watts
    Today I came across a wierd issue in a Visual Studio 2008 Code Coverage Analysis. Consider the following method:  private IController GetController<T>(IContext context) where T : IController, new() {     IController controller = new T();     controller.ListeningContext = context;     controller.Plugin = this;     return controller; } This method is called in a unit test as follows (MenuController has an empty constructor): controller = plugin.GetController<MenuController>(null);  After calling this method from a Unit Test, the following code coverage report is generated: As you can see, Code Coverage is only 85%. Looking up the code results in the following: Apparently, the call to the constructor of the generic type is considered only partly covered. WHY? Google didn't help. And MSDN didn't help at all, of course. Anybody who does know?

    Read the article

  • Java unit test coverage numbers do not match.

    - by Dan
    Below is a class I have written in a web application I am building using Java Google App Engine. I have written Unit Tests using TestNG and all the tests pass. I then run EclEmma in Eclipse to see the test coverage on my code. All the functions show 100% coverage but the file as a whole is showing about 27% coverage. Where is the 73% uncovered code coming from? Can anyone help me understand how EclEmma works and why I am getting the discrepancy in numbers? package com.skaxo.sports.models; import javax.jdo.annotations.IdGeneratorStrategy; import javax.jdo.annotations.IdentityType; import javax.jdo.annotations.PersistenceCapable; import javax.jdo.annotations.Persistent; import javax.jdo.annotations.PrimaryKey; @PersistenceCapable(identityType= IdentityType.APPLICATION) public class Account { @PrimaryKey @Persistent(valueStrategy=IdGeneratorStrategy.IDENTITY) private Long id; @Persistent private String userId; @Persistent private String firstName; @Persistent private String lastName; @Persistent private String email; @Persistent private boolean termsOfService; @Persistent private boolean systemEmails; public Account() {} public Account(String firstName, String lastName, String email) { super(); this.firstName = firstName; this.lastName = lastName; this.email = email; } public Account(String userId) { super(); this.userId = userId; } public void setId(Long id) { this.id = id; } public Long getId() { return id; } public String getUserId() { return userId; } public void setUserId(String userId) { this.userId = userId; } public String getFirstName() { return firstName; } public void setFirstName(String firstName) { this.firstName = firstName; } public String getLastName() { return lastName; } public void setLastName(String lastName) { this.lastName = lastName; } public String getEmail() { return email; } public void setEmail(String email) { this.email = email; } public boolean acceptedTermsOfService() { return termsOfService; } public void setTermsOfService(boolean termsOfService) { this.termsOfService = termsOfService; } public boolean acceptedSystemEmails() { return systemEmails; } public void setSystemEmails(boolean systemEmails) { this.systemEmails = systemEmails; } } Below is the test code for the above class. package com.skaxo.sports.models; import static org.testng.Assert.assertEquals; import static org.testng.Assert.assertNotNull; import static org.testng.Assert.assertTrue; import static org.testng.Assert.assertFalse; import org.testng.annotations.BeforeTest; import org.testng.annotations.Test; public class AccountTest { @Test public void testId() { Account a = new Account(); a.setId(1L); assertEquals((Long) 1L, a.getId(), "ID"); a.setId(3L); assertNotNull(a.getId(), "The ID is set to null."); } @Test public void testUserId() { Account a = new Account(); a.setUserId("123456ABC"); assertEquals(a.getUserId(), "123456ABC", "User ID incorrect."); a = new Account("123456ABC"); assertEquals(a.getUserId(), "123456ABC", "User ID incorrect."); } @Test public void testFirstName() { Account a = new Account("Test", "User", "[email protected]"); assertEquals(a.getFirstName(), "Test", "User first name not equal to 'Test'."); a.setFirstName("John"); assertEquals(a.getFirstName(), "John", "User first name not equal to 'John'."); } @Test public void testLastName() { Account a = new Account("Test", "User", "[email protected]"); assertEquals(a.getLastName(), "User", "User last name not equal to 'User'."); a.setLastName("Doe"); assertEquals(a.getLastName(), "Doe", "User last name not equal to 'Doe'."); } @Test public void testEmail() { Account a = new Account("Test", "User", "[email protected]"); assertEquals(a.getEmail(), "[email protected]", "User email not equal to '[email protected]'."); a.setEmail("[email protected]"); assertEquals(a.getEmail(), "[email protected]", "User email not equal to '[email protected]'."); } @Test public void testAcceptedTermsOfService() { Account a = new Account(); a.setTermsOfService(true); assertTrue(a.acceptedTermsOfService(), "Accepted Terms of Service not true."); a.setTermsOfService(false); assertFalse(a.acceptedTermsOfService(), "Accepted Terms of Service not false."); } @Test public void testAcceptedSystemEmails() { Account a = new Account(); a.setSystemEmails(true); assertTrue(a.acceptedSystemEmails(), "System Emails is not true."); a.setSystemEmails(false); assertFalse(a.acceptedSystemEmails(), "System Emails is not false."); } }

    Read the article

  • How to get code coverage when testing Silverlight

    - by Anonymous
    I'm looking for code coverage solution which works with silverligt. It must also work with msbuild because we run all the other unit tests automatically in the build server. Integration with Visual Studio and/or resharper is a plus and I have nothing against easy setup or a pointer to a tutorial. I don't usually modify the build files and unfortunately I don't have time to learn msbuild at the moment.

    Read the article

  • C++ code coverage tool

    - by prattipam
    I am looking for c++ code coverage tool which fares well in mutli server setup and on both windows and linux without licensing issues(if non free). I have done some research and found 2 free tools: Covtool and gcov. Any disadvantages on these or any other suggestions?

    Read the article

  • sonar code coverage issue

    - by user1490244
    Hi I am running sonar for my impl class, i have written junit for all the methods of impl class but when i ran the sonar the code coverage is just 11% and all the file is in red color. stating that the code is not covered. I really dont understand inspite of writing all the test methods for all the impl methods why is it showing such a less percentage. Any help or tips or guidelines will be greatly appreciated. Thanks

    Read the article

  • Setting up gcov in Xcode 3.1

    - by Algorithmic
    I'm trying to setup my Xcode project to be instrumented with gcov so I can determine the code coverage of my unit tests. All of the documentation I find online talks about settings that I don't find in Xcode 3.1, though. An example: To work with Coverstory, first you need to set up your target to work with gcov. This requires turning on "Instrument Program Flow", "Generate Test Coverage Files" and linking with the gcov library. (Using Coverstory) The closest thing I can find to "Instrument Program Flow" and "Generate Test Coverage Files" in my build settings is "Generate Profiling Code", which doesn't appear to do what I want it to do. Am I looking in the wrong place for these settings or are all of the examples I'm finding online stale?

    Read the article

  • eclipse gcov plugin

    - by Taani
    I am using gcov plugin in Eclipse CDT + cygwin compiler & linker to find code coverage. I installed gcov plugin from http://svn.sourceforge.jp/svnroot/ginkgo/trunk/org.ginko.gcov.update/ location and follow the below link to get coverage of my .c file. I was able to create .gcno and .gcda files. But double clicking on those files, opens the files in eclipse editor. I could not find the gcov editor. Also I couldn't see any code coverage results in my .c file. What is the wrong with my procedure?

    Read the article

  • Measuring code coverage for selenium tests that reside in separate project

    - by ilu
    I have two separate java maven projects: one is my web app itself and other one is tellurium+selenium automation tests for my web(I moved these tests to separate projects as their code doesnt really belong to the web app project code and doesnt use java classes of my web app, also I want to reuse some parts of those tests for testing my other web apps). Therefore, project where my tests reside doesnt know anything about my web app, except tellurium/selenium conf files(host name, credentials, browser). So the question: is there any way to measure code coverage of my webb app backend that is invoked by my tellurium/sellenium tests that reside in separate project? Thanks in advance. Any help is highly appreciated.

    Read the article

  • Multiple Condition Coverage Testing

    - by David Relihan
    Hi Folks, When using the White Box method of testing called Multiple Condition Coverage, do we take all conditional statements or just the ones with multiple conditions? Now maybe the clues in the name but I'm not sure. So if I have the following method void someMethod() { if(a && b && (c || (d && e)) ) //Conditional A { } if(z && q) // Conditional B { } } Do I generate the truth table for just "Conditional A", or do I also do Conditional B? Thanks,

    Read the article

  • Can you recommend an alternative for NCover?

    - by Keith
    I'm looking for a good .Net code coverage alternative to NCover (insufficient .Net 3.5 coverage and now pay-for) or VSTS (way too expensive). We currently test with NUnit, but could switch to something with a similar 'layout' for its text fixtures if it were better integrated.

    Read the article

  • How can CruiseControl.Net fail a build based on changing metrics?

    - by skolima
    I would like CruiseControl.Net to fail a build when some code metrics change in a 'wrong' direction, i.e. code coverage decreases or Gendarme defect count increases. The Gendarme metrics are already tracked in report.xml file (because they are presented on web dashboard graphs), the code coverage is only reported on build status page (and saved in build report xml). How can I achieve this?

    Read the article

  • No coverage for runtime with Devel::Cover and ModPerl::Registry

    - by codeholic
    When I'm running Devel::Cover with ModPerl::Registry, I get no coverage info except for BEGIN blocks. When I'm running the same script with Devel::Cover from command line or as a CGI, everything works alright (obviously). How can I make Devel::Cover "see" my code being executed in the runtime? Here's Devel::Cover related stuff in my httpd.conf: MaxClients 1 PerlSetEnv DEVEL_COVER_OPTIONS -db,/tmp/cover_db,silent,1 PerlRequire /var/www/project/startup.pl Here's startup.pl: #!/usr/bin/perl use strict; use warnings; use Apache2::Directive (); use File::Basename (); use File::Find (); BEGIN { # Devel::Cover database must be writable by worker processes my $conftree = Apache2::Directive::conftree->as_hash; my $name = $conftree->{User} or die "couldn't find user in Apache config"; print "user=$name\n"; my $uid = getpwnam($name); defined $uid or die "couldn't determine uid by name"; no warnings 'redefine'; local $> = $uid; require Devel::Cover; my $old_report = \&Devel::Cover::report; *Devel::Cover::report = sub { local $> = $uid; $old_report->(@_) }; Devel::Cover->import; } 1; (As you may see, I made a monkey patch for Devel::Cover since startup.pl is being run by root, but worker processes run under a different user, and otherwise they couldn't read directories created by startup.pl. If you know a better solution, make a note, please.)

    Read the article

  • How do I maximize code coverage?

    - by naivedeveloper
    Hey all, the following is a snippet of code taken from the unix ptx utility. I'm attempting to maximize code coverage on this utility, but I am unable to reach the indicated portion of code. Admittedly, I'm not as strong in my C skills as I used to be. The portion of code is indicated with comments, but it is towards the bottom of the block. if (used_length == allocated_length) { allocated_length += (1 << SWALLOW_REALLOC_LOG); block->start = (char *) xrealloc (block->start, allocated_length); } Any help interpreting the indicated portion in order to cover that block would be greatly appreciated. /* Reallocation step when swallowing non regular files. The value is not the actual reallocation step, but its base two logarithm. */ #define SWALLOW_REALLOC_LOG 12 static void swallow_file_in_memory (const char *file_name, BLOCK *block) { int file_handle; /* file descriptor number */ struct stat stat_block; /* stat block for file */ size_t allocated_length; /* allocated length of memory buffer */ size_t used_length; /* used length in memory buffer */ int read_length; /* number of character gotten on last read */ /* As special cases, a file name which is NULL or "-" indicates standard input, which is already opened. In all other cases, open the file from its name. */ bool using_stdin = !file_name || !*file_name || strcmp (file_name, "-") == 0; if (using_stdin) file_handle = STDIN_FILENO; else if ((file_handle = open (file_name, O_RDONLY)) < 0) error (EXIT_FAILURE, errno, "%s", file_name); /* If the file is a plain, regular file, allocate the memory buffer all at once and swallow the file in one blow. In other cases, read the file repeatedly in smaller chunks until we have it all, reallocating memory once in a while, as we go. */ if (fstat (file_handle, &stat_block) < 0) error (EXIT_FAILURE, errno, "%s", file_name); if (S_ISREG (stat_block.st_mode)) { size_t in_memory_size; block->start = (char *) xmalloc ((size_t) stat_block.st_size); if ((in_memory_size = read (file_handle, block->start, (size_t) stat_block.st_size)) != stat_block.st_size) { error (EXIT_FAILURE, errno, "%s", file_name); } block->end = block->start + in_memory_size; } else { block->start = (char *) xmalloc ((size_t) 1 << SWALLOW_REALLOC_LOG); used_length = 0; allocated_length = (1 << SWALLOW_REALLOC_LOG); while (read_length = read (file_handle, block->start + used_length, allocated_length - used_length), read_length > 0) { used_length += read_length; /* Cannot cover from this point...*/ if (used_length == allocated_length) { allocated_length += (1 << SWALLOW_REALLOC_LOG); block->start = (char *) xrealloc (block->start, allocated_length); } /* ...to this point. */ } if (read_length < 0) error (EXIT_FAILURE, errno, "%s", file_name); block->end = block->start + used_length; } /* Close the file, but only if it was not the standard input. */ if (! using_stdin && close (file_handle) != 0) error (EXIT_FAILURE, errno, "%s", file_name); }

    Read the article

  • eclipse CDT - Cannot open .gcda files

    - by Taani
    I am developing a coverage data tool in eclipse cdt. I used gcov and build and execute my C program to generate .gcda and .gcno files. When double click on .gcda file to see the coverage data, below error message displays. An error has occurred. See error log for more details. org.eclipse.linuxtools.binutils.utils.STSymbolManager.demangle(Lorg/eclipse/cdt/core/IBinaryParser$IBinaryObject;Ljava/lang/String;Lorg/eclipse/core/resources/IProject;)Ljava/lang/String; But I already downloaded and save org.eclipse.linuxtools.binutils_4.0.0.201209191645.jar into plugins directory. Where am I doing wrong?

    Read the article

  • eclEmma - full code coverage on class header?

    - by Fork
    Hi, I have a class that starts with: public class GeneralID implements WritableComparable<GeneralID>{ ... } And another that is: public class LineValuesMapper<KI, VI, KO, VO> extends Mapper<LongWritable, Text, Text, IntWritable>{ ... } All methods in these classes are covered. But not their header. The header of both classes gets painted as yellow with EclEmma. Is there anything I can do to fully cover the class header?

    Read the article

  • What framework would allow for the largest coverage of freelance developers in the media/digital mar

    - by optician
    This question is not about which is the best, it is about which makes the most business sense to use as a company's platform of choice for ongoing freelance development. I'm currently trying to decide what framework to move my company in regarding frameworks for web application work. Options are ASP.NET MVC Django CakePHP/Symfony etc.. Struts Pearl on Rails Please feel free to add more to the discussion. I currently work in ASP.NET MVC in my Spare time, and find it incredibly enjoyable to work with. It is my first experince with an MVC framework for the web, so I can't talk on the others. The reason for not pushing this at the company is that I feel that there are not many developers in the Media/Marketing world who would work with this, so it may be hard to extend the team, or at least cost more. I would like to move into learning and pushing Django, partly to learn python, partly to feel a bit cooler (all my geeky friends use Java/Python/c++). Microsoft is the dark side to most company's I work with (Marketing/Media focused). But again I'm worried about developers in this sector. PHP seems like the natural choice, but I'm scared by the sheer amount of possible frameworks, and also that the quality of developer may be lower. I know there are great php developers out there, but how many of them know multiple frameworks? Are they similar enough that anyone decent at php can pick them up? Just put struts in the list as an option, but personally I live with a Java developer, and considering my experience with c#, I'm just not that interested in learning Java (selfish personal geeky reasons) Final option was a joke http://www.bbc.co.uk/blogs/radiolabs/2007/11/perl_on_rails.shtml

    Read the article

  • Reflection in unit tests for checking code coverage

    - by Gary
    Here's the scenario. I have VO (Value Objects) or DTO objects that are just containers for data. When I take those and split them apart for saving into a DB that (for lots of reasons) doesn't map to the VO's elegantly, I want to test to see if each field is successfully being created in the database and successfully read back in to rebuild the VO. Is there a way I can test that my tests cover every field in the VO? I had an idea about using reflection to iterate through the fields of the VO's as part of the solution, but maybe you guys have solved the problem before? I want this test to fail when I add fields in the VO, and don't remember to add checks for it in my tests.

    Read the article

  • Get methods covered by a unit test

    - by Victor Hurdugaci
    Is is possible to do the following from a Visual Studio 2010 plugin? If yes, how? Run all unittests in solution (with code coverage enabled) Wait for all tests to complete For successfully completed tests: Determine which methods were called during each test (directly by the test or indirectly by the tested methods). What I actually don't know is how to interact with the testing framework...

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >