News for hackers. Stuff that matters.
Re:The OpenTF Manifesto by tedivm on Tuesday August 15, 2023 @12:27PM (#37135934)
Sorry, this may be a miscommunication. Terraform itself has a test suite, yeah, but it doesn't have a testing framework that users of the language can use to test their own code.

To make a python metaphor, if cpython had a testing suite but pytest didn't exist then people wouldn't be able to test their own python code. That's kind of the situation with Terraform right now- you can't test your code using just the Terraform tools, you have to rely on Terratest which was written by Gruntwork. Hashicorp has spent years relying on the open source community to fill those gaps, which Gruntwork has done very nicely.

Hashicorp even recommends Terratest for testing: https://www.hashicorp.com/blog/testing-hashicorp-terraform

Re:The OpenTF Manifesto by pseg134 on Tuesday August 15, 2023 @01:03PM (#37136392)
It isn’t a miscommunication, jen20 is astroturfing for hashicorp. Look at all of their recent posts.
Re:The OpenTF Manifesto by jen20 on Tuesday August 15, 2023 @01:35PM (#37136874)
"Astroturfing"... lol OK. I don't think I've ever made it a secret that I worked for HashiCorp in the early days (leaving in 2017), and have been critical to the point of being banned by the CEO from speaking at HashiConf.

Saying "Terraform doesn't have a test suite" is not miscommunication, it is misinformation, plain and simple - the same as most of the other things I have been correcting this week (not least from the same poster in this thread - someone who's clearly has an axe to grind).

Re:The OpenTF Manifesto by candiddevmike on Tuesday August 15, 2023 @03:48PM (#37138467)
You and the OP are referring to different things. Terraform the codebase has a test suite. Terraform the app does not have a test suite/runner as in a way to run tests against your Terraform files.
Re:The OpenTF Manifesto by jen20 on Tuesday August 15, 2023 @04:09PM (#37138730)
It doesn’t have a testing tool built in. No one legitimately understands the phrase “terraform doesn’t have a test suite” to mean anything except “there are no tests”. A runner and a suite are quite different.
Re:The OpenTF Manifesto by tedivm on Tuesday August 15, 2023 @07:08PM (#37140487)
I can understand the miscommunication in the first post, but I clarified in a direct comment to you what I meant. I was even comparing it to Terratest, which is not used for testing terraform core. At this point you're just being belligerent for the sake of being belligerent.
Re:The OpenTF Manifesto by jen20 on Tuesday August 15, 2023 @07:38PM (#37140824)
I'm not arguing with you, your clarifying comment was fine. I'm arguing with the person who replied to you.
Re:The OpenTF Manifesto by empressplay on Tuesday August 15, 2023 @02:29PM (#37137519)
Re:The OpenTF Manifesto by candiddevmike on Tuesday August 15, 2023 @02:57PM (#37137814)
No, that's a rough guesstimate from Terrafrom on what actions it will be doing. Terratest allows you to write actual tests and mocks.
Re:The OpenTF Manifesto by jen20 on Wednesday August 16, 2023 @10:27AM (#37147569)
This one needs some clarification.

It’s actually not a guesstimate about what actions will be taken, it’s a guesstimate of the state that will result from those actions without any reference to ordering or “actions” as a cloud API would understand them - the plan is purely in terms of CRUD on Terraform provider resources and provisioners.

This may seem like a nit, but it fundamentally changes what Terraform is capable of doing in a single pass without external coordination.