Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please help with finding out why the Junit test is coming back as a fail for the second method on Producttest package Jundt _ testing
Please help with finding out why the Junit test is coming back as a fail for the second method on Producttest
package JundttestingJtorres;
publis class poques
ciass fiejids
Whe will do data hiding, all will start with private keywords
private string prodName
private double prodprices
private int prodQtys
public ProductString prodName, double prodPrice constructor this.prodiName o prodNames
this prodprice o prodprices
public Productno aces constructor
public static void mainString args f
Product pI a new Product
plsetprodPrice
System.out.printinp Betprodprice
public String getProdName
return prodinames
public void setProdNameString prodName
this prodilame e prodvames
public double getprodPrice f
return prodprices
public void setprodPricedouble prodprice f
iffprodprice s e
thisoprodprice
else
thisoprodintice a prodpntices
public int geterrodogyQ
return prodedys
public void setifrodquy int prodoty is
this aprodety prodetys
pubitic string tosturing
return this Eetprodveme "this getProdPrice
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started