@@ -638,15 +638,14 @@ void shouldNotDeleteSchemaVersionInDryRunMode() {
638
638
@ Test
639
639
void shouldBulkDeleteAllSchemaVersions () {
640
640
Namespace namespace = buildNamespace ();
641
- Schema schema1 = buildSchema ();
642
- SchemaList schemaList = buildSchemaList ();
641
+ Schema schema = buildSchemaNameOnly ();
643
642
644
643
when (namespaceService .findByName ("myNamespace" ))
645
644
.thenReturn (Optional .of (namespace ));
646
645
when (schemaService .findByWildcardName (namespace , "prefix.subject-value" ))
647
- .thenReturn (Flux .fromIterable (List .of (schemaList )));
646
+ .thenReturn (Flux .fromIterable (List .of (schema )));
648
647
when (schemaService .getSubjectLatestVersion (namespace , "prefix.subject-value" ))
649
- .thenReturn (Mono .just (schema1 ));
648
+ .thenReturn (Mono .just (schema ));
650
649
when (schemaService .deleteAllVersions (namespace , "prefix.subject-value" ))
651
650
.thenReturn (Mono .just (new Integer [1 ]));
652
651
@@ -660,13 +659,12 @@ void shouldBulkDeleteAllSchemaVersions() {
660
659
@ Test
661
660
void shouldBulkDeleteSchemaVersion () {
662
661
Namespace namespace = buildNamespace ();
663
- Schema schema = buildSchema ();
664
- SchemaList schemaList = buildSchemaList ();
662
+ Schema schema = buildSchemaNameOnly ();
665
663
666
664
when (namespaceService .findByName ("myNamespace" ))
667
665
.thenReturn (Optional .of (namespace ));
668
666
when (schemaService .findByWildcardName (namespace , "prefix.subject-value" ))
669
- .thenReturn (Flux .fromIterable (List .of (schemaList )));
667
+ .thenReturn (Flux .fromIterable (List .of (schema )));
670
668
when (schemaService .getSubjectByVersion (namespace , "prefix.subject-value" , "1" ))
671
669
.thenReturn (Mono .just (schema ));
672
670
when (schemaService .deleteVersion (namespace , "prefix.subject-value" , "1" ))
@@ -715,14 +713,13 @@ void shouldNotBulkDeleteSchemaVersionWhenEmpty() {
715
713
@ Test
716
714
void shouldNotBulkDeleteAllSchemaVersionsWhenVersionNotFound () {
717
715
Namespace namespace = buildNamespace ();
718
- Schema schema = buildSchema ();
719
- SchemaList schemaList = buildSchemaList ();
720
- SchemaList schemaList2 = buildSchemaList2 ();
716
+ Schema schema = buildSchemaNameOnly ();
717
+ Schema schema2 = buildSchemaNameOnly2 ();
721
718
722
719
when (namespaceService .findByName ("myNamespace" ))
723
720
.thenReturn (Optional .of (namespace ));
724
721
when (schemaService .findByWildcardName (namespace , "prefix.subject*" ))
725
- .thenReturn (Flux .fromIterable (List .of (schemaList , schemaList2 )));
722
+ .thenReturn (Flux .fromIterable (List .of (schema , schema2 )));
726
723
when (schemaService .getSubjectLatestVersion (namespace , "prefix.subject-value" ))
727
724
.thenReturn (Mono .just (schema ));
728
725
when (schemaService .getSubjectLatestVersion (namespace , "prefix.subject2-value" ))
@@ -739,14 +736,13 @@ void shouldNotBulkDeleteAllSchemaVersionsWhenVersionNotFound() {
739
736
@ Test
740
737
void shouldNotBulkDeleteSchemaVersionWhenVersionNotFound () {
741
738
Namespace namespace = buildNamespace ();
742
- Schema schema = buildSchema ();
743
- SchemaList schemaList = buildSchemaList ();
744
- SchemaList schemaList2 = buildSchemaList2 ();
739
+ Schema schema = buildSchemaNameOnly ();
740
+ Schema schema2 = buildSchemaNameOnly2 ();
745
741
746
742
when (namespaceService .findByName ("myNamespace" ))
747
743
.thenReturn (Optional .of (namespace ));
748
744
when (schemaService .findByWildcardName (namespace , "prefix.subject*" ))
749
- .thenReturn (Flux .fromIterable (List .of (schemaList , schemaList2 )));
745
+ .thenReturn (Flux .fromIterable (List .of (schema , schema2 )));
750
746
when (schemaService .getSubjectByVersion (namespace , "prefix.subject-value" , "1" ))
751
747
.thenReturn (Mono .just (schema ));
752
748
when (schemaService .getSubjectByVersion (namespace , "prefix.subject2-value" , "1" ))
@@ -763,13 +759,12 @@ void shouldNotBulkDeleteSchemaVersionWhenVersionNotFound() {
763
759
@ Test
764
760
void shouldNotBulkDeleteAllSchemaVersionsInDryRunMode () {
765
761
Namespace namespace = buildNamespace ();
766
- Schema schema = buildSchema ();
767
- SchemaList schemaList = buildSchemaList ();
762
+ Schema schema = buildSchemaNameOnly ();
768
763
769
764
when (namespaceService .findByName ("myNamespace" ))
770
765
.thenReturn (Optional .of (namespace ));
771
766
when (schemaService .findByWildcardName (namespace , "prefix.subject-value" ))
772
- .thenReturn (Flux .fromIterable (List .of (schemaList )));
767
+ .thenReturn (Flux .fromIterable (List .of (schema )));
773
768
when (schemaService .getSubjectLatestVersion (namespace , "prefix.subject-value" ))
774
769
.thenReturn (Mono .just (schema ));
775
770
@@ -783,13 +778,12 @@ void shouldNotBulkDeleteAllSchemaVersionsInDryRunMode() {
783
778
@ Test
784
779
void shouldNotBulkDeleteSchemaVersionInDryRunMode () {
785
780
Namespace namespace = buildNamespace ();
786
- Schema schema = buildSchema ();
787
- SchemaList schemaList = buildSchemaList ();
781
+ Schema schema = buildSchemaNameOnly ();
788
782
789
783
when (namespaceService .findByName ("myNamespace" ))
790
784
.thenReturn (Optional .of (namespace ));
791
785
when (schemaService .findByWildcardName (namespace , "prefix.subject-value" ))
792
- .thenReturn (Flux .fromIterable (List .of (schemaList )));
786
+ .thenReturn (Flux .fromIterable (List .of (schema )));
793
787
when (schemaService .getSubjectByVersion (namespace , "prefix.subject-value" , "1" ))
794
788
.thenReturn (Mono .just (schema ));
795
789
0 commit comments