@@ -246,14 +246,20 @@ public void testDependencylessOpRecoveryFromString() {
246246 */
247247 @ Test
248248 public void testOpWithDependencyRecoveryFromString () {
249- OpInfo info = singularInfoOfName ("test.provenanceMapper" );
250- OpInfo dependency = singularInfoOfName ("test.provenanceMapped" );
251- InfoChain depChain = new InfoChain (dependency );
252- InfoChain chain = new InfoChain (info , Collections .singletonList (depChain ));
253- String signature = chain .signature ();
254- Nil <Function <Double [], Thing >> special = new Nil <>() {};
255- @ SuppressWarnings ("unused" )
256- Function <Double [], Thing > actual = ops .opFromSignature (signature , special );
249+ // Get the Op
250+ Function <Double [], Thing > mapper = ops //
251+ .op ("test.provenanceMapper" ) //
252+ .input (new Double [] {5.0 , 10.0 , 15.0 }) //
253+ .outType (Thing .class ) //
254+ .function ();
255+ // Get the signature from the Op
256+ String signature = history .signatureOf (mapper );
257+ // Generate the Op from the signature and an Op type
258+ Nil <Function <Double , Thing >> specialType = new Nil <>() {};
259+ Function <Double , Thing > actual = ops //
260+ .opFromSignature (signature , specialType );
261+ // Assert Op similarity
262+ Assertions .assertTrue (wrappedOpEquality (mapper , actual ));
257263 }
258264
259265 /**
@@ -379,14 +385,6 @@ public void testAdaptationWithDependencies() {
379385
380386 // -- Helper Methods -- //
381387
382- private OpInfo singularInfoOfName (String name ) {
383- Iterator <OpInfo > infos = ops .infos (name ).iterator ();
384- Assertions .assertTrue (infos .hasNext ());
385- OpInfo info = infos .next ();
386- Assertions .assertFalse (infos .hasNext ());
387- return info ;
388- }
389-
390388 /**
391389 * This method returns {@code true} iff:
392390 * <ol>
0 commit comments