Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,194,687 members, 7,955,578 topics. Date: Sunday, 22 September 2024 at 09:35 AM |
Nairaland Forum / Jacob05's Profile / Jacob05's Posts
(1) (2) (3) (4) (5) (6) (7) (8) (9) (10) (11) (12) (of 37 pages)
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:28pm On Aug 10, 2015 |
We'd Implement Mixed Fraction Later... Your thoughts ? |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:23pm On Aug 10, 2015 |
Implementing the Console App for Our Ordinary Fraction Operations Before we can make use of our Fraction Class in the Console App project we need to add a reference to the FractionLibrary project. 1) Right Click On References under FractionConsoleApp project in the Solution Explorer -> Click Add Reference [img]http:///a/img538/9408/1jN64u.jpg[/img] 2) Check FractionLibrary in the list. Click Ok [img]http:///a/img912/7441/hNFdXu.jpg[/img] 3) Update Program.cs in FractionConsoleApp[/b]project, adding [b] using FractionLibrary; Our Program.cs Class now
How do we go about implementing the operations…… Lets first write a simple algorithm … 1) Display Welcome Message 2) Display Available Operations 3) Accept Type of Operation to be performed 4) If Operation to be performed is a binary Operation a. Accept FirstFraction 1) If accepted value is not valid, request for another until correct value inputted b. Accept SecondFraction 1) If accepted value is not valid, request for another until correct value inputted c. Perform Selected Operation on two fractions 5) If Operation to be performed is a Unary Operation a. Accept SingleFraction 1) If accepted value is not valid, request for another until correct value inputted b. Perform Selected Operation on fraction 6) Output result 1. Display Welcome Message: Let’s create a method named displayWelcomeMessage to display necessary welcome message
2. Display Available Operations: We can write a method named displayAvailableOperations to display the Operations
3. Accept Type of Operation to be performed: We’d write a method named getTypeOfOperationToPerform to accept and return an integer value representing the type of operation the user wants to perform
4. If Operation to be is a binary Operation: Operations 1 to 4 requires two fractions, we need a condition to check this. So that we can accept two fractions.
5. Accept FirstFraction and Accept SecondFraction: Since these two steps are doing the same thing but with a different prompt. we can write a method named getSingleFractionFromUser to accept a fraction from the user which the two methods , getFirstFraction and getSecondFraction, we’re going to create, would call.
6. Perform Selected Operation on two fractions : To Implement this, we would need a condition to Determine which of the 4 binary operations is chosen. So that the need operation is performed. We’d create a method named performBinaryOperation that accepts, as arguments, the operation to be performed and the first and second Fraction. The method then returns the result.
7. If Operation to be performed is a Unary Operation: Operations 5 and 6 requires One fraction, we need a condition to check this. So that we can accept One fraction.
8. Accept SingleFraction: Let’s Create a method named getSingleFraction
9. Perform Selected Operation on fraction: To Implement this, we would need a condition to Determine which of the 2 Unary operations is chosen. So that the need operation is performed. We’d create a method named performUnaryOperation that accepts, as arguments, the operation to be performed and Fraction. The method then returns the result.
10. Output result: Let’s make this simple
PUTTING IT ALL TOGETHER Program.cs
|
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:18pm On Aug 10, 2015 |
IMPLEMENTING THE TOSTRING METHOD Overriding C#’s ToString method would enable us to define how we want our Fraction class to be displayed as a String. So that we can achieve the below [img]http:///a/img661/8026/uxIU5a.jpg[/img] Let’s Write the Tests in the tests class.
[img]http:///a/img540/6037/oTKPlN.jpg[/img] Let’s implement the method in the Fraction Class (NOTE: FOLLOW THE PASS -> FAIL -> PASS METHOD)
[img]http:///a/img540/2245/s3UnY6.jpg[/img] Run the tests !!! …. They should all pass .. [img]http:///a/img911/2290/hL7efq.jpg[/img] Now Let’s implement the Console App for Our Ordinary Fraction Operations. |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:13pm On Aug 10, 2015 |
IMPLEMENTING SYNTACTIC SUGARS What if we want to achieve something like this [img]http:///a/img661/5507/sHpT7q.jpg[/img] We can implement this by implementing a static implicit cast method on Strings; To best illustrate this syntactic sugar, let’s first write the test in the tests Class.
[img]http:///a/img905/4747/BxXj0j.jpg[/img] Let’s implement the method in the Fraction Class (NOTE: FOLLOW THE PASS -> FAIL -> PASS METHOD)
[img]http:///a/img912/3999/0Njo8J.jpg[/img] NOTE: the int.Parse method throws an Exception if the input String is not valid. Run the tests !!!.. They should pass. (NOTE: FOLLOW THE PASS -> FAIL -> PASS METHOD) [img]http:///a/img911/4578/ATzbPD.jpg[/img] Now Let’s implement the ToString method. |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:06pm On Aug 10, 2015 |
IMPLEMETING INCREMENT, DECREMENT, AND SYNATACTIC SUGARS Incrementing a fraction involves adding One to the fraction. But it is not that straight forward. To add 1 to a fraction we create a fraction with the Numerator and Denominator set to 1 and then we Add the fraction to our fraction. The same goes for decrement but we’ll do subtraction [img]http:///a/img901/9121/ngdmmi.jpg[/img] Ok. Just like Addition, we can implement increment and decrement using method and operator overloading. Let’s begin by writing our tests in the tests class
[img]http:///a/img673/1175/6VTdCS.jpg[/img] Our Code Won’t Compile because of the unimplemented method and operator. For the sake of brevity I would implement them directly not just implementing it just to make current test pass BUT you should follow the method I followed earlier by implementing a simple method that would make it pass then add another test that would fail the make it pass. Let’s implement them in the Fraction class.
[img]http:///a/img540/9593/OiYJOI.jpg[/img] Run the Tests Passed !!! [img]http:///a/img901/5940/r6gSuJ.jpg[/img] Let’s quickly implement Decrement in the tests class Our Tests for Decrement
[img]http:///a/img910/61/7bjY9t.jpg[/img] Our Code Won’t Compile because of the unimplemented method and operator. For the sake of brevity I would implement them directly not just implementing it just to make current test pass. Let’s implement them in the Fraction class.
[img]http:///a/img673/7899/w7vw7C.jpg[/img] Run the Tests Passed !!! [img]http:///a/img661/1806/fbWSoV.jpg[/img] |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 1:59pm On Aug 10, 2015 |
IMPLEMENTING SUBTRACTION, MULTIPLICATION AND DIVISION TESTS FOR SUBTRACTION
METHODS FOR SUBSTRACTION
TESTS FOR MULTIPLICATION
METHODS FOR MULTIPLICATION
TESTS FOR DIVISION
METHODS FOR DIVISION
Next, Run the tests. Passed !!! [img]http:///a/img909/4167/tA3B8s.png[/img] |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 1:43pm On Aug 10, 2015 |
BEGINNING TESTS: TESTING ADDITION OF ORDINARY FRACTIONS 2 The next Test Would be straight forward. We’d be leveraging on C#’s operator Overloading support to create a nice addition interface. Let’s write the Test !!!. Update the Test Method testOrdinaryFractionsAdditionsUsingOpOverloading to
Notice the Red wiggly under firstFraction + secondFraction and the message : Operator '+' cannot be applied to operands of type 'FractionLibrary.Fraction' and 'FractionLibrary.Fraction'; [img]http:///a/img540/2129/TKoSlp.png[/img] C# allow us to overload the + operator when use it on our class. This is done by creating method named operator followed by the + sign. Let’s Implement it to just [b] pass this test. Add this method to [b] Fraction.cs class
Weird Method Huh? You can Learn More about Operator Overloading via Google or Books. Notice the Red wiggly line is gone. Let’s Run the Test Again Passed !!! [img]http:///a/img538/4214/GuztLa.jpg[/img] Now Let’s make how test fail so that we can compute the values. Update the Test Method testOrdinaryFractionsAdditionsUsingOpOverloading
Run the Tests.. It Should Fail, With the Message : Expected<190> .Actual<75> Now Let’s Make it Pass By Updating the Overload Method to do actual Calculation.
Save and Run the test File Again. Tests should Pass FractionArithmeticTests.cs
Fraction.cs
FROM THE ABOVE, IMPLEMENTING SUBTRACTION, MULTIPLICATION AND DIVISION WOULD BE VERY EASY SO I WON’T DISCUSS MUCH ON IT BUT WOULD PASTE THE TESTS AND METHODS. I’D ADVISE YOU FOLLOW THE STEPS I FOLLOWED WHILE IMPLEMENTING THE ADDITION OPERATION. FIRST MAKE THE TEST COMPILE BY ADDING A RETURN VALUE THAT WOULD JUST MAKE IT PASS. THEN ADD ANOTHER TEST THAT WOULD MAKE IT FAIL THEN, FINALLY, FIX THE FUNCTION TO MAKE THE THIS PASS. |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 11:30am On Aug 10, 2015 |
Check My Posts Again...Updated the Posts |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 11:28am On Aug 10, 2015 |
I noted a Veeeeery BIG logical error in the Whole App.... I feel very ashamed ... But why can't you guys point it out in the first Place... Calculations for Addition and the rest are totally wrong !!!!.... |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 11:25am On Aug 10, 2015 |
Finally.. Back online |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 1:43pm On Aug 07, 2015 |
i'm sorry i haven't updated and conclude this simple tut. Lost my phone. (my hotspot lolz). I would torrent all the remain updates when i secure a good internet source. thanks for your contributions and followership |
Software/Programmer Market / Re: Create Us A Facebook Video Downloader For Android For #75,000 by jacob05(m): 1:36pm On Aug 07, 2015 |
lordZOUGA:exactly. |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 8:08pm On Aug 06, 2015 |
dhtml18:thanks...hmmmm...native dialect..lolx |
Computer Market / Re: Thinkpad X240 Intel Core I5 4gb Ram 128gb Ssd Keyboard Light, Fingerprint 4 ~55k by jacob05(m): 9:37am On Aug 06, 2015 |
interested |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 11:35pm On Aug 05, 2015 |
Bros1:thanks.. I would |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 11:34pm On Aug 05, 2015 |
ibrodex:thanks bro !!!...same ibrodex from kp |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:36pm On Aug 05, 2015 |
updates loading |
Nairaland / General / Re: A Thread For Night Crawlers. (late Sleepers) by jacob05(m): 2:09am On Aug 05, 2015 |
romme2u:hmmmm |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 6:33pm On Aug 04, 2015 |
Pffft:valid points.... I'm not a fan of try ...catch too..I've thought about it while writing the tutorial and thanks for pointing it out again.. but the test is actually intensional and It's meant to be discussed on later.... |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:59pm On Aug 04, 2015 |
UPDATES LOADED... LOADING MORE LATER.. but i need your responses |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:58pm On Aug 04, 2015 |
Updated: 10/08/2015 11:43 BEGINNING TESTS: TESTING ADDITION OF ORDINARY FRACTIONS For Addition Tests, Let’s Create a new Test Method Named testOrdinaryFractionsAdditions
There are two ways we can implement this in C# 1) Using method 2) Using Operator Overloading Hmmmm.. Lets Implement Both in Parallel !!!. Rename testOrdinaryFractionsAdditions to testOrdinaryFractionsAdditionsUsingMethod and Add a new Test Method Named testOrdinaryFractionsAdditionsUsingOpOverloading Now let’s write a test for Addition Using Method.Let’s write how the interface would look like then make it compile
Notice the Red wiggly Line under firstFraction.Add . [img]http:///a/img912/2290/YSFEGL.jpg[/img] That’s because it’s not yet Implemented. Click on the Add method, Hover the Little blue line under it then click Generate Method Stub. Update the generated Add Method in Fraction.cs to
Question: Oga Jacobu, Why did you just return a Fraction object like that without any calculation or something? Answer: That’s TDD for you, you write test progressively in simple baby steps to just pass the current test. Then later we write another test that would prompt the correction of the logic. Simple huh ? Now, Let’s run the test and ensure we pass it . Yup !!! Test passed Next, Let’s Update testOrdinaryFractionsAdditionsUsingMethod to test for Another Pair of Fractions.
Run the Test Again.. It should fail. Yep, It does. With Message : Expected<50> .Actual<75> [img]http:///a/img537/9666/usAS97.jpg[/img] It Failed because, for our previous test to pass, we just returned a new Fraction object in the Add Method with the values we expected. Now, Let’s Implement the Calculation from the Logic Discussed Earlier. Update Add Method to
Save and Run the Test File. Passed !!! [img]http:///a/img913/192/Ee0EqJ.jpg[/img] |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:44pm On Aug 04, 2015 |
BEGINNING TESTS: FURTHER TESTING ORDINARY FRACTION CREATION 2 So, far how test value for creation of the Ordinary Fraction objects has been quite predictable. What if a curious user inputs 0 (zero) for either Numerator or Denominator via our constructor? While this can be avoid by checking the input value before using them to create Fraction objects. We (I) don’t want the class to be “DEFENSELESS”. We to throw an Exception of invalid input supplied. So, Let Amend our FractionArithmeticTests class with this
In the Above Test, We’re trying to Assert that Fraction class with a numerator value of 0 is not instantiate-able. We want our Fraction class to throw an Exception ArgumentOutOfRangeException . if the Object throws the Exception (ArgumentOutOfRangeException) for firstFraction = new Fraction(0, 1); then is caught, nothing is done, skips Assert.Fail("Shouldn't be Able to Create a Fraction with Zero Numerator" , and passes the test. Otherwise, If Fails. Let’s Try and run our Test Again.. (Fingers Crossed)… Right Click Anywhere on the FractionArthmeticTests Code ..A Dialog Appears, Click On Run Tests !!! Congratulations !!! Our First Failed Test [img]http:///a/img661/1235/weV1vE.jpg[/img] Our test failed as expected with the Message “Shouldn't be able to Create a Fraction with Zero Numerator” . Notice the Red Bar when our Test Fails and also Green when our test Pass. These is the TDD Life Cycle [img]http:///a/img537/6002/mhIrAv.jpg[/img] Red: Make your test Fail by writing a failing test Green: Make you test Pass by implementing the needful Refactor: Make the Code Right by remove redundant codes or duplicates. Our Next Step is to make our Test by implementing validation before values are assigned. We do it in two ways.. 1) Validating the values in the constructor before assigning it to properties 2) Validating the values while setting value in the Property I’d go with the first, Why ?, Because I choose to …. LOLz Ok … Lets Edit Our Fraction Class and Implement the validation of Numerator.
That Done, Let’s Run Our Test Again. Yes !!!, Test Passed !!! [img]http:///a/img673/6189/X7GPrz.jpg[/img] Next, Let’s Test That Denominator can be Zero too.. Add a new try..catch Block in the testOrdinaryFractionCreation Method in FractionArithmeticTests after the previous try..catch Block
Let’s run our Test Again.. Right Click Anywhere on the FractionArthmeticTests Code ..A Dialog Appears, Click On Run Tests !!! Congratulobia !!!. Our Test Failed Again with the message "Shouldn't be able to Create a Fraction with Zero Denominator" [img]http:///a/img537/7495/GADsEo.jpg[/img] Now Let’s make our test pass by checking the denominator before assignment in the constructor Update Ok … Lets Edit Our Fraction Class and Implement the validation of Denominator.
Run the Test Again. Yes, (Dancing Shokiti Bobo),(Dtml18) our test passed !!!. [img]http:///a/img911/6486/rIbJif.jpg[/img] That’s about it, for now, with Ordinary Fraction Creation Test. Pls let me know other tests that can be performed. Fraction.cs
FractionArithmeticTests.cs
|
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:29pm On Aug 04, 2015 |
Viewing this topic: lordZOUGA(m) ... hi boss .. waiting to hear from you |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:19pm On Aug 04, 2015 |
[sup][/sup] BEGINNING TESTS: FURTHER TESTING ORDINARY FRACTION CREATION Test Cycle 1. Add a little test 2. Run all tests and fail 3. Make a little change 4. Run the tests and succeed 5. Refactor to remove duplication Now, Test Further … Let’s Test our Super Fraction class by creating a new Fraction with Numerator of 5 and Denominator of 10 These we want to pass to the Fraction Class Constructor. Update testOrdinaryFractionCreation method
Notice the Red wiggly line. [img]http:///a/img661/2473/CWO9ag.jpg[/img] Our Tests won’t run until with fix or implement the construct. Click on the Fraction(5,10) , Hover the Little blue line under it then click Generate Stub.. Amend the Generated Stub so that we have
But Notice we still have Another Error .. Red wiggly line under new Fraction() [img]http:///a/img901/472/FxGxuQ.jpg[/img] With Error Message [img]http:///a/img673/3497/CAlB6A.jpg[/img] This is because of the new Constructor we’ve just create. If a class has no constructor , “C#” creates an empty constructor for us. but if any constructor is declared, it does not create it. In our case, we need to create another constructor that accepts no value. Let’s Go There !!! So, like before, Click on the Fraction() , Hover the Little blue line under it then click Generate Stub.. Our Fraction.cs class now
Visual Studio Should bug you again. Right Click Anywhere on the FractionArthmeticTests Code , A Dialog Appears, Click On Run Tests !!! Our code Should work and build successfully passing the test. Note: We haven’t had any failed test yet.. well that’s because C# has been helpful defaulting new properties to 0 (in the case of creating new empty Fraction) and we’ve not really done much. You can test Further with new values
|
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 4:04pm On Aug 04, 2015 |
Fixed Wrong Images placements |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:53pm On Aug 04, 2015 |
BEGINNING TESTS Now our project is ready for Development. Question: What should we test? Test (To Me) should be done on behaviours (methods) in our apps that returns a result that of value for us to pass our acceptance test. Going to Our Requirements, we to create Fractions that can be used for Arithmetic operations. Why not begin with testing for proper creation of ordinary Fraction Objects? Let’s Go back to Visual Studio. 1) Rename the Generated Class UnitTest1.cs in our Unit Test Project to FractionArithmeticTests.cs and the Class name to FractionArithmeticTests (if not Refactor-ed automatically) 2) Open FractionArithmeticTests.cs and add a new method named testOrdinaryFractionCreation with [TestMethod] Decorator Our Class, FractionArithmeticTests.cs , Should Look like this
When writing test, we write how we want our class interface to look like without necessarily creating them yet. Going back to Code.
[img]http:///a/img661/7277/37fGW0.jpg[/img] Question: But Wait ooo. Oga Jacobu. Are you ok? How can we test a Class that doesn’t exist yet? Answer: That’s the plan !!! Welcome to TDD. We’re writing how our Class objects interface should look like before writing the actual Class. We always write Tests at first that won’t compile (Notice the Red wiggly line under Fraction Class). Then we make it compile. After which our test library Asserts it False then we make it Pass !!!.. Our Next Step now is to make our App Compile by Creating the Class and implementing the property. 1) Right Click On FractionLibrary in the Solution Explorer -> Add -> Click Class [img]http:///a/img912/9877/bIjhou.jpg[/img] 2) Name the Class Fraction.cs [img]http:///a/img910/696/avIp7z.jpg[/img] We have (Note Make the Class Public)
3) Next You’d Observe the Red wiggly isn’t gone yet. This is because our Fraction Class is Another Project and namespace. We need to add a Reference to the FractionLibrary Project in our Fraction Project. 4) Right Click On References under FractionTest project in the Solution Explorer -> Click Add Reference [img]http:///a/img540/3117/lJm6qK.jpg[/img] 5) Check FractionLibrary in the list. Click Ok [img]http:///a/img673/8473/i6Kz3a.jpg[/img] 6) Update FractionArthmeticTests.cs by adding using FractionLibrary; Our FractionArthmeticTests.cs Class now
But We Still Can’t Compile Yet Because the Two Properties Numerator and Denominator are not declared in our class. [img]http:///a/img537/2171/6Lpl68.jpg[/img] 7) Let’s Add them …. Update Fraction.cs .. Note you can use Visual Studio’s Generate Stub to Quick Add missing methods or properties… Click on the Property, Hover the Little blue line under it then click Generate Stub [img]http:///a/img633/5951/YguFhq.jpg[/img] Repeat for Denominator too.
Our Project Should build in peace now !!!... Right Click Anywhere on the FractionArthmeticTests Code ..A Dialog Appears, Click On Run Tests !!! [img]http:///a/img537/4129/wU1Qiv.jpg[/img] 9) Congratulations !!! We’ve just Passed a Test [img]http:///a/img910/1765/RBAA9O.jpg[/img] |
Programming / Re: How Can I Create A Virus Or Malware? by jacob05(m): 9:00am On Aug 04, 2015 |
DonSegmond:Lolz... A very valid point expressed in a very wrong manner 1 Like |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 8:58am On Aug 04, 2015 |
Pffft:Thanks for following. hope make the much needed contribution I require. I'd post the major tests today once I get my internet sub fixed.. |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 7:51am On Aug 04, 2015 |
valonsoft:Thanks... |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 6:32am On Aug 03, 2015 |
Updates coming soon |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 3:25pm On Aug 02, 2015 |
PROJECT SETUP For this Tutorial, You’d need Microsoft Visual Studio (Express, Professional, Ultimate ) installed on your system. Once installed , with Visual C# included, we can proceed. Our Solution Layout We’d create three separate projects in our solution. 1) FractionConsoleApp : Contains our Console App 2) FractionLibrary : Contains our App Classes 3) FractionTest : Contains our Test Classes So, to begin, Launch Visual Studio. 1) Select File -> New -> Project [img]http:///a/img537/5614/lCECS0.jpg[/img] Select Visual C# from Templates in the Left Pane; Choose Console Application in the Center Pane. For Project Name: FractionConsoleApp and Solution name: FractionArithmeticApp . Click Ok [img]http:///a/img910/7241/FMXTx6.jpg[/img] Our newly Created Solution [img]http:///a/img901/7421/OeR4lw.jpg[/img] 2) Next, Right Click on the Solution Name -> Add -> Click New Project [img]http:///a/img673/1190/otu4r1.jpg[/img] 3) Choose Class Library in the Center pane; For Project Name: FractionLibrary .Click Ok [img]http:///a/img913/2198/QGyT6z.jpg[/img] Repeat Step (4), Select Test in Left pane and Select Unit Test Project in the Center pane; For Project Name: FractionTest .Click Ok [img]http:///a/img901/9225/J6MDMM.jpg[/img] 4) Our Solution’s Structure should look like this [img]http:///a/img673/2589/kF2TFl.jpg[/img] |
Programming / Re: Tutorial: Building A Simple Fraction Arithmetic Program In C# Using TDD by jacob05(m): 12:11pm On Aug 02, 2015 |
Contributions pls? 1 Like |
(1) (2) (3) (4) (5) (6) (7) (8) (9) (10) (11) (12) (of 37 pages)
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 141 |