ChatGPT - How Long Till They Realize I’m a Robot?

Image
I tried it first on December 2nd... ...and slowly the meaning of it started to sink in. It's January 1st and as the new year begins, my future has never felt so hazy. It helps me write code. At my new company I'm writing golang, which is new for me, and one day on a whim I think "hmmm maybe ChatGPT will give me some ideas about the library I need to use." Lo-and-behold it knew the library. It wrote example code. It explained each section in just enough detail. I'm excited....It assists my users. I got a question about Dockerfiles in my teams oncall channel. "Hmmm I don't know the answer to this either"....ChatGPT did. It knew the commands to run. It knew details of how it worked. It explained it better and faster than I could have. Now I'm nervous....It writes my code for me. Now I'm hearing how great Github Copilot is - and it's built by OpenAI too...ok I guess I should give it a shot. I install it, and within minutes it'...

NAnt for automating builds in C# works fine....

I've been learning NAnt the past few days, and it's really quite simple.  Unfortunately, using it with NUnit isn't.  I'm supposed to be able to use NAnt to build my projects automatically and test them too, all with one quick call to a batch file:

./build.bat test

where build.bat just calls nant.exe and passes it a buildfile, which is an xml file that includes "targets" for nant to run.  NAnt compiles my project and my test project just fine, but then when NUnit runs, I get some messed up errors.  I can run my tests properly in Visual Studio using ReSharper, and they behave properly, but it doesnt work on the command line using NAnt...what the crap is up?!

A couple notes for you:
my folder structure is as follows :
src : contains application projects in one folder (app) and test projects in another (test)
build : should be deleted and rebuilt every time NAnt runs
config : contains config files for the project
tools : contains the NAnt folder and the NUnit folder including the exe's and dll's
lib : 3rd party libraries
base : contains the above folders, as well as the .sln, the batch file and the buildfile for NAnt.

There were a few solutions that seemed to work for various scenarios, but I think the one that will work most consistently (and unfortunately is a bit cumbersome) is this:

Use NAnt to clean and rebuild your projects and tests into a single folder (/tmp).  Then, place all the NUnit dll's directly into that same folder.  Any references to NUnit should point to the copy in the tools folder.  Then, when everything is built and the NUnit dll's are placed in the tmp folder, run the tests from the base directory through NAnt by creating a new "target" in the buildfile that runs nunit-console.exe.  The target should have no dependencies. You may also need to add this to the nunit-console.exe.config file:

underneath the configuration opening tag put:
<startup><supportedruntime version="v4.0.30319"/>
and under the runtime opening tag put:

<loadfromremotesources enabled="true" />
I'll have to do this everytime I build, until I figure it out...lame.

P.S. I learned to use NAnt from my bro, and from here:

http://blog.developwithpassion.com/2006/04/automating-your-builds-with-nant-part-1

Comments

  1. Thank you for sharing your insights! Much like this post of you :)


    Check out our site for more:
    ecommerce templates

    ReplyDelete

Post a Comment

Popular posts from this blog

ChatGPT - How Long Till They Realize I’m a Robot?

My experience with Udacity

Architectural Characteristics - Transcending Requirements