a test framework for CFML (ColdFusion).
Questions tagged [mxunit]
18 questions
                    
                    18
                    
            votes
                
                3 answers
            
        ColdFusion unit test frameworks
As a related sub-question - are there any CF unit test frameworks that support or make it easier to use mocks/stubs?
The 2 that I spotted in a quick google that look the most promising are MXUnit and CFUnit.  Are there others, and which one(s) have…
        
        jinglesthula
        
- 4,446
 - 4
 - 45
 - 79
 
                    6
                    
            votes
                
                1 answer
            
        Test Isjson in MXUnit
I am working on the MxUnit test frame work for CFML. In it, I want to check whether the return value of a function is a valid JSON or not. Currently I am using: 
assertEquals(True,IsJSON(userEventItems),'The return must be json');
Is there any…
        
        Uthandu Murugan.M
        
- 61
 - 2
 
                    5
                    
            votes
                
                2 answers
            
        Best practice with Coldfusion deployment
I'm new to Coldfusion development and inherited an already deployed project.
Due to various technical limitation, it is not possible to develop locally on our workstations (like you would do for .net). As a consequence, the files are edited directly…
        
        E. Jaep
        
- 2,095
 - 1
 - 30
 - 56
 
                    5
                    
            votes
                
                2 answers
            
        application variables are not found when running MXUnit test from Eclipse
So I was following the tiny guide here on how to run a single MXUnit test with Eclipse using the MXUnit plugin for Eclipse. But as you can see in the screen shot below it didn't work out for tests that I know work, because it appears that the…
        
        erikvold
        
- 15,988
 - 11
 - 54
 - 98
 
                    5
                    
            votes
                
                1 answer
            
        Setting up MXUnit for multiple webroots (on a single box) such that the preferences don't need to be constantly changed for MXUnit's location
Background
When we want to create a ColdFusion application (in our development environment, a separate box from my PC) we setup an IIS (internet information services) site with a physical location holding all the CFCs CFMs etc that make up our…
        
        Richard Tingle
        
- 16,906
 - 5
 - 52
 - 77
 
                    4
                    
            votes
                
                3 answers
            
        What's the best way to unit test a cfc that uses a Java object for a lot of its functionality?
I have a cfc that relies heavily on a Java object (created via JavaLoader) for a lot of its core functionality that I'd like to write some tests for and I'm not sure what the best way to do this is. Here is an example of a method I'd like to write a…
        
        bittersweetryan
        
- 3,383
 - 5
 - 28
 - 42
 
                    4
                    
            votes
                
                2 answers
            
        Order of function execution in mxunit testcase
I'm using MxUnit as a testing framework for my ColdFusion project. But I'm not sure about, in which order the functions in the testcase is getting executed. I've inserted dummy records in DB for my testing, in beforeTests() and deleting those…
        
        Rajesh Manilal
        
- 1,104
 - 9
 - 20
 
                    4
                    
            votes
                
                2 answers
            
        mock/stub Component with MXUnit
I have a component called ComponentUnderTest.cfc looking as:
     
        
            
            
                
                    
    
    
        
    
    
                
            
        
       
        Yvo Volders
        
- 51
 - 4
 
                    3
                    
            votes
                
                1 answer
            
        examples of unit testing methods that are expected to return JSON
How does one unit test an object or collection - specifically a JSON packet??
Do you just test for he structure, key/values pairs? regardless of values??
Do I create an empty collection? and compare?
same question applies to any complex object…
        
        j-p
        
- 3,698
 - 9
 - 50
 - 93
 
                    3
                    
            votes
                
                0 answers
            
        MXUnit add return value when using throws()
I'm trying to write an MXUnit test for a component I'm mocking up that throws an error. When it throws an error of a certain type I get a struct back from the service I'm calling. Is there a way to mock up a struct and return that with the mock?
The…
        
        Matt Busche
        
- 14,216
 - 5
 - 36
 - 61
 
                    2
                    
            votes
                
                1 answer
            
        session invalidate and creating a new session
I'm using ColdFusion 10 and J2EE session variables. To log a user out (end a session) I'm using getPageContext().getSession().invalidate() this works fine until I run my MXUnit tests and one of them tests the logout process. The session is…
        
        Matt Busche
        
- 14,216
 - 5
 - 36
 - 61
 
                    2
                    
            votes
                
                1 answer
            
        MXUnit mocking permission denied
I was finally able to get mxunit and mocking working on my local Windows install but after the sys admin installed it on our Linux server I get the following error only when I use it. It works fine for another app that does not require…
        
        Aaron
        
- 1,042
 - 2
 - 12
 - 30
 
                    1
                    
            vote
                
                1 answer
            
        Testing an array of structures in mxunit
What is the best way to test a function that returns an array of structres in mxunit?  Right now i'm doing something like this:
var actual = variables.pbj.getFunctions();  //returns [{name="getAccountNumber", value="0"},{name="getAccountName",…
        
        bittersweetryan
        
- 3,383
 - 5
 - 28
 - 42
 
                    1
                    
            vote
                
                0 answers
            
        Using MXUnit or is there another way to display coldfusion output using Intellij IDEA 15
I'm loving IntelliJ because I also work with MySQL and the integration into one UI is great. Seems that IntelliJ works nicely with ColdFusion as well. I'm just hoping to successfully use MXUnit, but I seem to be getting an error upon testing. My…
        
        BE-RIZZY
        
- 11
 - 3
 
                    1
                    
            vote
                
                2 answers
            
        Hudson is giving error while creating the test report
I am getting the follwoing error from Hudson. Could any one please tell me what is wrong here. My test cases are working fine.
Total time: 0 seconds
Recording test results
ERROR: Failed to archive test reports
  hudson.util.IOException2: remote…
        
        nasaa
        
- 2,701
 - 8
 - 47
 - 76