No need to say much about the classical ASTM D638 tensile test specimens AKA dogbones. Just a few remarks:
Figure above reference:ASTM D638, Standard Test Method for Tensile Properties of Plastics, ASTM International, West Conshohocken, PA, 2014, www.astm.org
Cadquery scripts:
import cadquery as cq
# ASTM D638 typeI dogbone
W = 13.0
L = 57.0
WO = 19.0
LO = 165.0
R = 76.0
thickness = 3.2
dogbone_typeI = (cq.Workplane("front").box(LO, WO, thickness).
faces(">Y").workplane().rect(L, thickness).cutBlind(-(WO-W)/2).
faces("<Y").workplane().rect(L, thickness).cutBlind(-(WO-W)/2).
faces(">Z").workplane(centerOption='CenterOfBoundBox').
rect(L, 2*R+W, forConstruction=True).vertices().hole(2*R))
show_object(dogbone_typeI)
import cadquery as cq
# ASTM D638 typeIV dogbone
W = 6.0
L = 33.0
WO = 19.0
LO = 115.0
R = 14.0
RO = 25.0
thickness = 3.2
dogbone_typeIV = (cq.Workplane("front").box(LO, WO, thickness).
faces(">Y").workplane().rect(L, thickness).cutBlind(-(WO-W)/2).
faces("<Y").workplane().rect(L, thickness).cutBlind(-(WO-W)/2).
faces(">Z").workplane(centerOption='CenterOfBoundBox').
rect(L, 2*R+W, forConstruction=True).vertices().hole(R*2).
edges("|Z").edges("not <X or >X").fillet(RO))
show_object(dogbone_typeIV)