2

Today checked my learning time tracker. I have spent already 80 hours for learning angularjs. And I still am not able to write unit test without errors. What the fuck. How many hours more do I need to finnaly be able to write unit tests without any problem?
Like today getting

An error was thrown in afterAll\nSyntaxError: Unexpected token 'export'

and I do not even use afterAll() funciton so they give error somewhere from the inside of libraries. Why they do that? why cannto they give easy to understand error?

Everytime I sit to write unit test for learning, all the time I feel I will not understand. And I am right everytime. Damn. That makes me need to force motivate myself. I want to see results, not sit at the same place so many time.

Comments
  • 1
    >80 hours

    it takes 10 000 hours to become a master at something! You have a long way ahead of you ;)

    ofc this depends on the type of practice, and what type of learner are you... but just to be sure assume at least a couple of hundred to a couple of thousand at least!
  • 0
    @Hazarth I am not to master every single detail, I just want basic skills :) jquery I learned much faster. But not done unit tests with jquery.
  • 0
    You say couple of hundred. You know to get that much hours after work is hard. I also want to do other things in my life.
  • 0
    @Angry-dev

    pffft... life?!!! Other things?!!! fun?!!!

    Should've think of that before you became a developer!!

    You're the modern sla... sorry, you're the modern replica.
  • 0
    @Hazarth I dont see better option. I just see trading better option but need to learn that first, learning curve is even harder than learning angular it feels like. Write a bot and let him earn me money and then I wach money growing and have lot of free time :D
  • 0
    @Angry-dev That's the dream, isn't it?...

    I think you can download bots that do that already and just let them run, I'm pretty sure we had one running in our company. But it doesn't really make you rich fast or anything like that...

    I heard before that the stock market is unpredictable. To write a bot that can actually do good trading you'd need to look for global news not just previous data series... most bots still only do very opportunistic trading where they try to "guess" when the least risk is, but still only trade relatively small amounts so they don't lose more than they earn.

    One of these days I want to write a bot that actually follows a bunch of stock market websites and tries to predict some of the market value from it... but then again even with that info you're still the last in the line to know about it... you can bet your ass that *some* people have inside knowledge and can act before the market changes even though it's illegal :D
  • 0
    @Hazarth yea, the dream. At least while not doing it :) actually thats a business. WHich has risks. When you are employee, you more or less get fixed money every month or every hour. I do not know how I would feel having big risks :) maybe then I would miss stable salary :)
  • 0
    "I think you can download bots that do that already and just let them run, I'm pretty sure we had one running in our company. But it doesn't really make you rich fast or anything like that..."

    You can but who will give bot which makes money for free? I do not even try to search for that.
  • 0
    "I heard before that the stock market is unpredictable. To write a bot that can actually do good trading you'd need to look for global news not just previous data series... most bots still only do very opportunistic trading where they try to "guess" when the least risk is, but still only trade relatively small amounts so they don't lose more than they earn."

    I heard that also but I heard also that market is predictable. I am thinking that those who say its unpredictable, just put too little work in finding patterns. Of course I cannot prove because I had not made money but thats what I am thinking from other people talking who claim they beat the market without the analissis of news.
  • 0
    I am just thinking that people who give up too early, do not put enough work into styding patterns.
    Who knows, maybe I am wrong.
  • 0
    "One of these days I want to write a bot that actually follows a bunch of stock market websites and tries to predict some of the market value from it... but then again even with that info you're still the last in the line to know about it... you can bet your ass that *some* people have inside knowledge and can act before the market changes even though it's illegal :D"

    with bot I really dont think you are last on the line. There are many manual traders who click mouse and trade. So you are faster at least vs them. But I am thinking if you are not trading on seconds timeframe, there is no worry. Like if you predict price will go to X in one hour. If everyone would think same, price would then instantly go to that X. But it takes hour to go to X, so maybe you lose few ticks because of somebody is faster, but still have long way till it moves during that hour. Yea, during news releases price might go super fast.
  • 0
    Other people dont trade during the news, they trader after market calms down but price still moves slowly.
  • 0
    Why Angularjs in 2021?
  • 0
    No stack trace?

    Oh well I guess sometimes that doesn't really help much when working with component frameworks because if the test is based on some mocked state and fails immediately on setup it can be rather unintuitive to figure out where in the midst of all the bootstrapping the error occurrs.
  • 0
    I don't know angular tests but for tests in general I really recommend setting up a debugger!

    It's useful to be able to step from the running test into your actual code. Even if the error gives you a stack trace - sometimes you really need to step to realise the flow.

    Quite often you notice some function got a strange parameter due to a bad mocked test data or not doing cleanup after previous test.
  • 0
    @nibor because our company uses it
  • 0
    @jiraTicket setting up a debugger would be good. Just not sure how to do it for js consolle :)
  • 0
    Btw found way finnaly how to write the test
Add Comment