Jump to content


JKI Team
  • Content Count

  • Joined

  • Last visited

Everything posted by JKI

  1. Yes, EasyXML works great on LabVIEW Real-Time (RT). However, EasyXML depends on some OpenG Array Tools (oglib_array) package, which has some version dependencies you should be aware of: On LabVIEW Real-Time 2009 or newer, you should have no problems. On LabVIEW Real-Time 8.x, you should install oglib_array 2.7 or earlier. The reason for this is that oglib_array 3.0 added support for LabVIEW Classes and Objects (objects-oriented programming), which is supported in LabVIEW 8.x, but is not supported in LabVIEW Real-Time 8.x (and therefor causes the OpenG Array Library and EasyXML to be broken). LabVIEW Real-Time 2009 added support for LabVIEW Classes and Objects, so oglib_array 3.0 works fine in this environment without any issues.
  2. For some reason, upgrading to LabVIEW 8.6.1 can cause the "VI Server: Exported VIs" settings to get reset in a way that prevents VIPM from being able to connect. To fix this, do the following: LabVIEW's VI Server permissions are not configured correctly for VIPM. In the LabVIEW options dialog (Tools>>Options) go to the "VI Server: Exported VIs" page and ensure that you entered a value of "*" (see below).
  3. This is the Known Issues list for VI Tester 1.1.2. For issues fixed in current & previous releases of VI Tester, please see the Release Notes. Known Issues Case 10909: 'Run Single Test' generates an error when pressed after reloading a project Reloading a project does not disable the 'Run Single Test' button which makes it possible to press the button when no test is selected, resulting in an invalid test selection error dialog. Workaround: Do not press 'Run Single Test' until you've selected a test on the test tree after reloading project. Case 10911: VI Tester UI Doesn't Always Open on German Localization of LabVIEW VI Tester UI won't open from the Getting Started Window menu, or from a project (.lvproj) menu. Workaround: Open VI Tester from the VI Tester toolbar on the project window or from the menu of an open VI. Case 10770: VI Tester UI Should Warn Users if Test has unsaved changes. VI Tester uses the saved class on disk to find test methods. If the class has changes in memory, VI Tester should warn users to save Test class(es). Workaround: Manually save test classes prior to opening VI Tester UI. Case 11703: VI Tester Setup, and test methods required interface (TestCase in, TestCase out, error in (no error), error out, are case sensitive. VI Tester searches for the inputs/outputs by name and is case sensitive. Can create problems if user modifies the names from the template. Workaround: Don't rename controls/indicators that are created from the template. Case 11980: VI Tester TestCase.Setup method has typo on reference indicator. Test Cases instantiated by TestCase template have 'reference in' label on the reference output. This should be labelled as 'reference out'. Workaround: This bug does not have any adverse effects on tests (cosmetic bug). Case 13680: VI Tester Toolbar Icons not visible in LV2011, LV2012 Project toolbar buttons not visible and/or have missing icons. Workaround: Use the Tools Menu to launch VI Tester.
  4. VI Tester requires the following software: LabVIEW 8.2.1 or greater on any operating system VI Package Manager 2.0 or greater (free download)
  5. Here are some of the things that are on our radar. If you've got ideas or feedback please post them in VI Tester forum -- everything here is open for discussion. Run Test Programmatically -- high-level VIs for running tests programmatically (instead of from the VI Tester GUI) Right-click on tests in VI Tester GUI: Skip / Don't Skip, Run Test, Open Test VI Performance optimizations Inheritance and overrides of custom Test Cases and Test Suites Export test report 'Detailed Status' to printer/disk/clipboard Improved project file integration
  6. Moved here: https://github.com/JKISoftware/JKI-VI-Tester
  7. Background VI Tester is a LabVIEW implementation of the xUnit test framework architecture. It is an object-oriented framework with several core classes and a graphical user interface for loading and running tests. Terminology VI Tester - Graphical Test Runner UI The graphical user interface that loads and runs tests (which you launch by selecting Tools >> VI Tester >> Test VIs... from the LabVIEW menubar). When you open a Project, Test Case, or Test Suite, VI Tester searches for tests in Test Cases and Test Suites. You can then run the tests. Core Class: TestCase.lvclass All Test Cases must inherit from "TestCase.lvclass". This core class contains several utility methods for setting the pass/fail status, and performing other operations in test methods. This class also contains several other methods that are used by the framework for running tests. Core Class: TestSuite.lvclass All Test Suites must inherit from "TestCase.lvclass". This core class contains several utility methods for configuring tests in the test suite. Test Case (contains your tests) Any class that inherits from "TestCase.lvclass" (for example, a Test Case that you create by selecting Tools >> VI Tester >> New >> Test Case... from the LabVIEW menubar). A Test Case contains Unit Tests (a.k.a Test Methods) as well as optional Setup and Teardown methods. Test Suite (your groupings of tests) Any class that inherits from "TestSuite.lvclass". A Test Suite contains a collection of "Test Objects", which are either TestCase.lvclass or TestSuite.lvclass objects. Unit Test / Test Method A Test Case member VI whose name begins with the word "test" Setup A Test Case member VI named "setUp.vi". Teardown A Test Case member VI named "tearDown.vi".
  8. JKI

    Debugging Tests

    VI Tester is a tool to help you pinpoint problems with your code. As your application evolves, you will want to regularly run unit tests to validate that none of the tests fail. If a test fails, it generally means that there is a problem with the code that is being tested - but it can sometimes mean that there is a bug in the test itself. Either way, you'll want to fix the problem. A test can fail in three places: in the actual test method (most likely), but also in "setUp.vi" (called once before each test method is executed) and "tearDown.vi" (called once after each test method is executed). When a test fails, it will appear on the "Failures" tab (and will also show a red "X" as its glyph in the "Test Hierarchy" tree). Switch to the "Failures" tab and double click the test of interest to open it. The VI where the failure was detected will open (setUp, test method, or tearDown). Tests can fail due to a failure being raised or an error being raised. If an error is raised, the test will appear as Error. One easy way to debug the test is to enable LabVIEW's Retain Wire Values tool and re-run the test. You can now trace the data that was passed into and out of your test VI. Here's a short video showing how easy it is to debug test VIs: If you have any feedback or questions (including ideas for other topics you'd like to learn more about), please consider posting them to the VI Tester Discussion Forums. We're looking forward to your feedback.
  9. JKI

    Creating New Tests

    Add a new test case to your project. A "test case" is a special LabVIEW class that contains unit test methods. VI Tester recognizes unit test methods as members of a test case class whose name starts with "test". To get started, please watch this brief tutorial video and then follow the walkthrough below. You can create a new test case by selecting Tools >> VI Tester >> New >> Test Case... from the menubar of the Project Explorer window. Browse to a folder where you want to create the test case, type a name for the test case, and press the "OK" button. VI Tester will create a folder for your test case (having the same name as your test case). Inside this folder will be your new test case class along with some other useful VIs. The new test case class will will be added to your LabVIEW project and under the "My Computer" node. Add a new unit test (method) to your new test case. To create new tests, save a new copy of "testExample.vi" using the "Open additional copy" option of the "Save As" dialog. Make sure to check the box that says 'Add copy to {MyTest}.lvclass' where {MyTest} is the test you created. Customize the unit test and its pass/fail criteria. The following video gives a short tutorial on how to define the test pass/fail criteria: Tests pass when there are no test failures or errors. You can write tests quickly by using the built in test evaluations found on the Test Case palette, shown below: For example, if you need to test that an error is raised, use 'passIfError.vi'. If none of the built-in evaluations is sufficient for the type of test you need to perform, you can use the Error status to define test behavior, any test with an Error will fail. But, don't branch your test case object wire! Note: Be careful not to branch the TestCase object wire! The easiest way to avoid this, is to treat the TestCase object wire much like you would treat the error cluster, never allow it to branch. Good (no branching of the TestCase object): Note how the object wire is not branched. Bad (branching of the TestCase object): Note that the object wire is branched. VI Tester will not be able to evaluate the result correctly. Move on to designing a test. If you've gotten this far, why not learn some other aspects of designing a test.
  10. JKI

    Designing Tests

    Unit tests should be designed around the following principles: Unit tests should be simple - you don't want to spend time debugging tests Unit tests should only test one thing (a "unit" of code) - unit tests should help you pinpoint problems so performing multiple tests within a unit test defeats this purpose Unit tests should be independent of other unit tests - they should not depend on or affect other unit tests To facilitate these principles, unit tests should be designed to work within a test harness. A test harness is a set of VIs called 'setUp.vi' and 'tearDown.vi' that run before and after each unit test method. The test harness facilitates keeping your code simple and preventing tests from interfering with each other by providing a place to initialize and cleanup the test data. Any task that is common to the test methods you need to run should be placed in the setUp.vi method. Any task that is needed to clean up the test environment should be put in tearDown.vi. An important aspect of the unit test framework is how data is passed from the setUp to the testMethod and tearDown.vi. The data that is passed around are actually properties of the test and so these items should be placed in the test object private data. You can edit this data by opening the {Test}.ctl file. Now that you've designed your new test, you should read some tips on how to easily debug your test.
  11. Please watch this short tutorial on how to run unit tests from VI Tester. After watching the video, you can follow them step by step in the walk through below. Open the VI Tester example project located at: \examples\JKI\VI Tester\VI Tester Example.lvproj The example project, shown below contains two TestCase classes: Expand the "Merge Errors TestCase.lvclass" class in the tree to show the class members. You will find several member VIs whose names all begin with "test" -- these are unit tests that validate functionality of the "Merge Errors" VI that ships with LabVIEW. We'll look at these later. Now, let's run all the tests. Launch the VI Tester user interface by selecting Tools >VI Tester > Test VIs... from the menubar of the Project Explorer window. VI Tester will then inspect the project for all unit tests and show them in the Test Hierarchy window, as shown below. Press the 'Run All Tests' button to run all of the unit tests. This will run all of the tests, showing the results. The following glyphs are used to show the status of each test: - Test Passed - Test Failed - Test Skipped - Test Not Run You can double-click any of the tests, to open it. Double-click on the "test no error in" test in the "Merge Errors TestCase". This will open "Merge Errors TestCase.lvclass:test no error in.vi", as shown below: You can see that the "Enabled" frame of the Diagram Disable Structure calls "TestCase.lvclass:skip.vi" -- this is why the test shows the Test Skipped () icon in VI Tester. Enable the other frame of the Diagram Disable Structure, as shown below: The re-run the test to see that it is no longer skipped. Interested, and want to see more? Why not learn how to add new Test Cases to a Project?
  12. You have a few minutes and just want to learn what VI Tester is about. VI Tester helps you perform unit testing on your VIs. Unit testing is a way to validate that your code works at the lowest (i.e. unit) levels. In LabVIEW, the lowest level of testing is the VI. When you write effective unit tests you get two benefits: 1) you can verify that when you modify code, you don't create unintended bugs 2) when your tests fail, you can quickly pinpoint the root cause of your failure. To start, you launch VI Tester window from the LabVIEW Tools Menu. Next, open a project file that contains unit tests. To run the tests, you can press the 'Run all tests' button. You can easily review the test status and see a log that was generated while running the tests. The following video shows just how easy it is to run tests in VI Tester. VI Tester makes it really easy to run unit tests on your LabVIEW code. If you have more time, why not try installing VI Tester and then running some unit tests to see for yourself?
  13. Moved here: https://github.com/JKISoftware/JKI-VI-Tester/wiki/VI-Tester-FAQ
  14. Download and Install VI Tester from JKI Labs Note: The full-featured version of the JKI VI Tester is licensed under the JKI Toolkits Evaluation License. To download and install VI Tester, you will need VIPM (VI Package Manager), which is made freely available by JKI. If you don't already have VIPM installed, you can get it from our website, here. Also, make sure to check the System Requirements for VI Tester. Installing VI Tester takes less than a minute. Here are the steps: Update Your Package List Install VI Tester Restart LabVIEW 1) Update Your Package List From VIPM's toolbar, press the Check the Network for Available Packages button. VIPM will connect to the Internet and obtain an updated list of all the available packages. After VIPM completes this operation, you may see a dialog stating that there were new packages found and asking you if you want to install them. Press the no/cancel button and proceed to the next step. 2) Install VI Tester Find the jki_labs_tool_vi_tester package in the package list (hint: type "tester" into the quick search text box to find the VI Tester package). Right-click on it and select the Install right-click menu option, as shown below: VIPM may ask you if you wish to install other dependency packages, in addition to jki_labs_tool_vi_tester. Make sure that all the dependency packages remain selected and press OK, as shown below. VIPM will download all required packages and begin the installation process. During the installation process, VIPM will present you with a license agreement dialog (shown below) for VI Tester software. If you agree to the terms of the license agreement, press the "Yes" button to proceed with the installation process. 3) Restart LabVIEW After the installation process completes, restart LabVIEW. You are now ready to start using VI Tester. What Next? Read the VI Tester Getting Started Guide, of course
  15. What's New in VI Tester 1.0 Initial public release.
  16. Moved here: https://github.com/JKISoftware/JKI-VI-Tester/wiki/Getting-Started-Guide-and-Resources
  17. VI Tester™ (jkisoft.com/vi-tester) Copyright © 2007-2009 James Kring, Inc. All Rights Reserved. VI Tester, JKI Labs, and other JKI Software logos and design are trademarks of James Kring, Inc. in the United States and/or other jurisdictions. All other marks and names mentioned herein may be trademarks of their respective companies. OpenG Toolkit libraries (openg.org) The OpenG Toolkit libraries used in VI Tester are licensed under the terms of the BSD (http://www.opensource.org/licenses/bsd-license.php) and are copyright of the following: 2002 Cal-Bay Systems, Inc., 2002 Jean-Pierre Drolet, 2002-2006 Jim Kring, 2003 Paul F. Sullivan, 2008 T. Plomp 2002-2007 Cal-Bay Systems, Inc., Jim Kring. 2006-2007 MKS Instruments, Inc. 2002 Jean-Pierre Drolet, Jim Kring 2002 2003 Cal-Bay Systems, Inc., 2002-2006 Jim Kring, Rolf Kalbermatter 2002-2006 Jean-Pierre Drolet, Jim Kring 2002-2007 Jim Kring, 2002 Cal-Bay Systems, 2004 Paul Sullivan, 2004 Michael C. Ashe, 2005-2006, MKS Instruments, Inc. (author: Doug Femec) Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of the nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. Crystal Clear Icon Set (www.everaldo.com/crystal) Copyright © Everaldo Coelho. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. NUVOLA ICON THEME for KDE 3.x (www.icon-king.com) Copyright © 2003-2004 David Vignoni. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
  18. Hi Jed, Sorry for the trouble. BTW, we've got some info in our FAQ about this: Can I install VIPM on Windows Vista? We haven't added any special features for Vista, yet, as it's still not officially supported. But, it's on our roadmap. Thanks, -Jim
  19. We at JKI are excited to announce the release of VIPM 2.0.3 on the Mac, Linux, and Windows operating systems. This release includes fixes for several minor issues as well as minor usability improvements. Please see the VIPM 2.0.3 Release Notes page for more information. To download and install the latest version of VIPM, visit http://jkisoft.com/vipm/.
  20. jkisoft.com First, you should ask your IT department to allow access to jkisoft.com (this one is required, since this is where VIPM gets the package list from). *.dl.sourceforge.net Next, you'll need access to one or more sourceforge mirrors: *.dl.sourceforge.net (where * can be any one of the sourceforge mirror names). For example: easynews.dl.sourceforge.net kent.dl.sourceforge.net switch.dl.sourceforge.net superb-east.dl.sourceforge.net puzzle.dl.sourceforge.net Here is the most recent set of mirrors and their geographic locations: easynews: Phoenix, AZ (North America) superb-west: Seattle, Washington (North America) internap: San Jose, CA (North America) superb-east: McLean, Virginia (North America) voxel: New York, New York (North America) puzzle: Bern, Switzerland (Europe) mesh: Duesseldorf, Germany (Europe) ovh: Paris, France (Europe) dfn: Berlin, Germany (Europe) heanet: Dublin, Ireland (Europe) garr: Bologna, Italy (Europe) surfnet: Amsterdam, The Netherlands (Europe) kent: Kent, UK (Europe) transact: Canberra, Australia (Australia) internode: Adelaide, Australia (Australia) waix: Perth, Australia (Australia) jaist: Ishikawa, Japan (Asia) nchc: Tainan, Taiwan (Asia) ufpr: Curitiba, Brazil (South America) Note: You can configure the order you want to use the mirrors in the Advanced page of the Tools>>Options dialog.
  21. I can see a case for having VIPM bring itself to the front after the package build is complete -- it does present a dialog telling the user that the build has completed. I'll pass this along to the rest of the VIPM developer team. The window title of VIPM's package building window is "PACKAGENAME - VIPM - VI Package Builder". Note that PACKAGENAME does not include the version number.
  22. The reason for this is that build hook VIs run in the target LabVIEW development environment and VIPM is its own executable application. So, opening a modal dialog in LabVIEW won't make the build hook's dialog come frontmost, if LabVIEW isn't frontmost (which it won't be, since you're probably interacting with VIPM). Also, build hooks can do anything they like, but VIPM has no way to know that you intend them to have user interaction. There are at least a couple possible ways to address your use case. 1) VIPM could possibly make LabVIEW frontmost while it is running the build hooks and then bring itself frontmost again after the build hook completes execution. 2) The build hook could make itself come frontmost -- this can be done with Windows API calls. It should be careful to bring VIPM frontmost again, after it's done, so that the user doesn't wonder why VIPM went away. I'm trying to think if #1 would cause any usability problems for running build hooks that are not user-facing. One solution might be to have a "bring LabVIEW to front when running build hooks" option, but I really dislike adding new options, if it's possible (even with a bit of work) to make the software simply work as expected in all situations.
  23. Nowhere. The paid version of EasyXML does not need to be activated or unlocked. The serial number sent to you when you purchased EasyXML is simply for your records. You may need this SN in the future for upgrades and special offers to existing customers.
  24. After you have completed the download and installation process, restart LabVIEW. You should then be able to find the EasyXML VIs in the Functions palette at JKI Toolkits >> EasyXML (shown below). See also: How come I can't see EasyXML in the Functions palette?
  25. One of the trickiest little features of EasyXML is creating scalar elements with attributes. Granted, it's not entirely obvious -- but, don't worry, it's still as easy as creating a cluster Before we show you how it's done, let's review some of the EasyXML basics. (If you'd like to skip the review, scroll down to the Scalar Elements with Attributes section, below.) Scalar Elements Scalar elements can be created from strings, Booleans, numerics, and other scalar LabVIEW data types. For example, here is a scalar numeric: EasyXML treats clusters and arrays as compound elements (meaning that they have child elements). Compound Elements Clusters are compound elements with dissimilar child element names: Arrays are compound elements with the same name: Attributes Compound Elements with Attributes To add attributes to an element, put a cluster named "#attributes" inside a cluster. For example, here is a compound element with attributes: Scalar Elements with Attributes Now, to add attributes to a scalar element, things get tricky. We have to follow the same process used for creating compound element with attributes, but with a twist: we use only one scalar child element having the same name as the parent cluster. Recall our scalar element: To add attributes to this scalar element, we have to do the following: 1) convert the scalar into a cluster 2) add an "#attributes" cluster 3) add a scalar element with the same name as the parent cluster Here's what that looks like: List of Scalar Elements with Attributes You can create multiple same-named scalar elements with attributes in the same way you create a list of normal scalars. Just drop the cluster inside of an array, as shown in the screenhot, below. Make sure that you name the array, since the cluster name will be ignored (since array element names are always ignored by EasyXML). Download the Example VI Scalar_Element_with_Attributes_Example.vi (Saved in LabVIEW 7.1) (Note, you'll need to download the EasyXML demo in order to run this example, if you don't already have the demo or full version installed.)
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.