A Reactrospective: A React Retrospective

James Bradley Angular, Development Technology, HTML5, JavaScript, React Leave a Comment

Most, if not all, of my experience has been with .NET and .NET Core. I’ve also worked with most of the front-ends throughout history including Classic ASP, Code Behind, Model View Presenter, MVC, Backbone, and, over the last few years, Angular 1… Angular 6… not Angular 2…AngularJS. To me, AngularJS is that old t-shirt that you put on to sleep in; comfortable.

At first, most of us on the team were a bit apprehensive about moving to React. AngularJS was very familiar and Angular 2 seemed like the natural next step. I could learn TypeScript, and as primarily C#-based developer, I really liked the idea of a little typing. I like shiny new things, and I’m always game to learn, so challenge accepted. Since then I’ve had a hand in writing three applications in React and have learned more than a few lessons. These are their stories… dun dun.

Getting Started with Marble Testing

Todd Leininger Testing, Tutorial Leave a Comment

When working with RxJS observables, it can get a little tricky to unit test. Sometimes it can be hard to get insight into what is going on with the observable in the test. I’ve personally been frustrated numerous times by trying to test my observables with the subscribe and assert method. This is where marble testing can make testing observables easier.

The main advantage of using marble testing is the marble diagrams. With the diagrams, we have a visual representation of our observables and subscriptions so we can see the interactions between the two. Once the basics are understood, you should be able to get observable tests running in no time.

In this post, I will show you how to get started using Marble testing with an example. By the end, you should have enough information to get started on your journey testing observables. My examples are based on an Angular application using Jasmine, but these can also be applied to different testing frameworks for React and other applications.