JUnit's @Parameterized runner provides support for parameterized tests.
Questions tagged [parameterized]
525 questions
-1
votes
1 answer
Parameterized version like Spring Boot
I want to parameterize Maven version as a variable like Spring Boot.
Every submodule use version as ${revision} .
@see git@github.com:iPhotoner/parameterized-version-demo.git

selfy
- 1
- 3
-1
votes
1 answer
JUnit 5 and multiple input data (Java)
How to use JUnit 5 to run series of tests of a computation, each for a different pair of input data and benchmark output?
Condition: the computation should be performed only once per input and not for every test separately as it is…

Mateusz
- 39
- 2
-1
votes
1 answer
How to mock 0 or 1 invocation with jmockit
@Test
public void test() {
new NonStrictExpectations() {
{
aService.method1(anyString); result=abc
}
};
}
I am using Parameterized runner with jmockit.
Now method1 of aService may or may not…

Anil Punia
- 37
- 3
-1
votes
2 answers
Asp.net Authentication Error not logging in the user
I have my login form and i tried to parameter the query for logging in user. But it seem to give an error that Login failed for user. My code is here. Please tell me what am i doing wrong here.
public void LoginUser()
{
string UserNameFromHTML…

adil sharif
- 55
- 1
- 4
- 14
-1
votes
1 answer
java interfaces and parameters types
I'm trying to parameterize a generic type with an interface and Eclipse tells me that method abc() is not implemented for the type T. Of course it is not implemented since T is an interface, the program will figure out at runtime what T really is.…

Lexy
- 25
- 3
-1
votes
1 answer
An expression of non-boolean type specified in a context where a condition is expected, paramerization using DbCommand in c#
I have this function to execute a parameterized select query:
public string LookUp(string sColuna, string sTabela, string sWhere)
{
string[] Parameters = { "@column", "@table", "@where" };
var comando = @"SELECT @column FROM @table WHERE…
-1
votes
1 answer
Parameterise functions to automate website using selenium webdriver with Python
I want to automate the login functionality of a site in such a way that i just pass the different values of username and password as parameters and the login functionality is tested for each pair of values.
example:
def login(username,password):
…

Akshay Malhotra
- 29
- 1
-1
votes
1 answer
parameterized SQL script
SET ECHO ON
SET VERIFY ON
ACCEPT CNUMBER CHAR PROMPT 'CUSTOMER NUMBER == '
ACCEPT PNUMBER CHAR PROMPT 'PART NUMBER == '
ACCEPT OD date format 'YYYYMMDD' PROMPT 'ORDER DATE == '
DELETE FROM ORDERS WHERE CNUM = &CNUMBER AND PNUM = &PNUMBER AND…

monster king
- 1
- 2
-1
votes
2 answers
Pass Variable Number of Parameters to Postgresql
How does one pass a random number of parameters to a query? The below code blocks show what was attempted. All of the failures displayed bool(false). For testing, three integers are used to represent ids.
The query from item 1 was manually…

Dave
- 84
- 9
-2
votes
1 answer
how to use parametized Junit tests for this string reverse code
I read somewhere that I can use @RunWith(JUnitParamsRunner.class) but I have no idea how to use it to test my string reverse method:
Here's my class:
public class StringReverse {
public static String reverse(String s){
List…

D. Ace
- 398
- 4
- 9
- 25
-2
votes
2 answers
C# MySql Parameterized Query makes longs into null
The code is based on https://dev.mysql.com/doc/connector-net/en/connector-net-programming-prepared-preparing.html
public void TableTest(string connectionString)
{
string sqlToCreateTable = @"CREATE TABLE IF NOT EXISTS my_table
…

Patrick
- 351
- 1
- 6
- 20
-2
votes
3 answers
Issue with creating an object from a parameterized constructor with an array as a parameter
I'm working on a Java project for a Yahtzee game and need to create a parametrized constructor that gives both of my instance variables their values. My two instance variables are arrays.
public DiceArray(int[] die)
{
die = new int[5];
…

Espinal
- 3
- 2
-3
votes
2 answers
parameterized data structures in haskell
Can you advise on how to represent parameterized data structures in haskell? e.g. in an application which represents contents of a garments shop, I might have instances of racks for men's and women's clothes. These parameters can be hierarchical,…

R71
- 4,283
- 7
- 32
- 60
-3
votes
1 answer
Functions in Oracle. Need to search and find the passed paramater using Oracle Function
I have a requirement like , I need to search and find a value of a table column using Oracle Parameterized function.
Suppose, if my table has a column called 'Name' which has 2 records like 'mike', 'steve'.
I need to create a function where I will…
-4
votes
2 answers
When I run a C# parameterized query to handle single quotes, it still throws an exception error on a single quote. How can I make this work?
Here is my code... It works fine for input data that does not have a single quote, but when I enter a single quote and try to Post it crashes. I've tried many code samples and this should work. Any help would be appreciated.
string SQLcommand =…

John Crispin
- 7
- 1