BridgesUNCC / bridges-client-testing

Repo that will contain coding samples to test the BRIDGES software
0 stars 1 forks source link

Bridges C++ tests. #31

Open krs-world opened 5 years ago

krs-world commented 5 years ago

We need to fix the C++ tests, so that we deallocate the BRIDGES object (and any other allocated object) before termination. And make sure there is a return code for the main() - should return 0, which is the normal return code.

   -- krs
krs-world commented 5 years ago

And then update the BRIDGES website with the tests being used there.

esaule commented 5 years ago

Note that there is no reason to allocate the BRIDGES object dynamically to begin with. Then deallocation will be done by the compiler when main scopes out.

krs-world commented 5 years ago

So good practice is if you have  allocation calls, also have deallocation calls. One of our users pointed out that..

The alternative is not to use dynamic allocation for BRIDGES object, as you say.

    -- krs

On 1/27/19 9:51 PM, Erik Saule wrote:

Note that there is no reason to allocate the BRIDGES object dynamically to begin with. Then deallocation will be done by the compiler when main scopes out.

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/krs-world/Bridges_Testing/issues/31#issuecomment-457983824, or mute the thread https://github.com/notifications/unsubscribe-auth/AFZSOFDBjNdEuljFobZxxGnhnF58Wb84ks5vHmWpgaJpZM4aVB9a.

-- Kalpathi Subramanian Ph: 704 687 8579 Associate Professor Email: krs@uncc.edu Dept of Computer Science Web:http://webpages.uncc.edu/krs The University of North Carolina Charlotte, NC 28202-0001

Amarix commented 5 years ago

Ok, I can update the tests. Do we want to deallocate the bridges objects that are already there or do we want to remove allocation all together?

esaule commented 5 years ago

I think we should cut it altogether. That the RAII way of doing it.

@krs-world, opinion?

krs-world commented 5 years ago

Its fine.. didnt you once say that we might need to pass the Bridges object around - to the data acquisition related part of the s/w?

    -- krs

On 1/28/19 6:19 PM, Erik Saule wrote:

I think we should cut it altogether. That the RAII way of doing it.

@krs-world, opinion?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/krs-world/Bridges_Testing/issues/31#issuecomment-458341963, or mute the thread https://github.com/notifications/unsubscribe-auth/AFZSOL2eDA3O3Pvv3YMFW8m0xU0fQpQNks5vH4WUgaJpZM4aVB9a.

esaule commented 5 years ago

indeed, we will need to. but that is unrelated to how the object is allocated to begin with. (or did you mean we should change that as well?) -- Sent from my Android device with K-9 Mail. Please excuse my brevity.