File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed
jvm/selfie-lib/src/commonMain/kotlin/com/diffplug/selfie Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -88,5 +88,20 @@ object Selfie {
88
88
@JvmStatic
89
89
fun <T > cacheSelfieBinary (roundtrip : Roundtrip <T , ByteArray >, toCache : Cacheable <T >) =
90
90
CacheSelfieBinary <T >(deferredDiskStorage, roundtrip, toCache)
91
- @JvmStatic fun vcrTestLocator (sub : String = "") = VcrSelfie .TestLocator (sub, deferredDiskStorage)
91
+
92
+ /* *
93
+ * Whichever file calls this method is where Selfie will look for `//selfieonce` comments to
94
+ * control whether the VCR is writing or reading. If the caller lives in a package called
95
+ * `selfie.*` it will keep looking up the stack trace until a caller is not inside `selfie.*`.
96
+ */
97
+ @JvmStatic
98
+ @VcrBeta
99
+ fun vcrTestLocator (sub : String = "") = VcrSelfie .TestLocator (sub, deferredDiskStorage)
92
100
}
101
+
102
+ @RequiresOptIn(
103
+ level = RequiresOptIn .Level .WARNING ,
104
+ message = " This API is in beta and may change in the future." )
105
+ @Retention(AnnotationRetention .BINARY )
106
+ @Target(AnnotationTarget .CLASS , AnnotationTarget .FUNCTION , AnnotationTarget .PROPERTY )
107
+ annotation class VcrBeta
You can’t perform that action at this time.
0 commit comments