<commit_before>package nexus_test

import (
	"fmt"
	"github.com/hanjos/nexus"
	"github.com/hanjos/nexus/credentials"
	"github.com/hanjos/nexus/search"
	"reflect"
)

func Example() {
	n := nexus.New("https://maven.java.net", credentials.None)

	// obtaining all repositories in Nexus
	repositories, err := n.Repositories()
	if err != nil {
		fmt.Printf("%v: %v", reflect.TypeOf(err), err)
		return
	}
<commit_msg>Testing if nexus.Nexus2x satisfies nexus.Client.<commit_after>package nexus_test

import (
	"github.com/hanjos/nexus"
	"github.com/hanjos/nexus/credentials"
	"github.com/hanjos/nexus/search"

	"fmt"
	"reflect"
	"testing"
)

func TestNexus2xImplementsClient(t *testing.T) {
	if _, ok := interface{}(nexus.Nexus2x{}).(nexus.Client); !ok {
		t.Errorf("nexus.Nexus2x does not implement nexus.Client!")
	}
}

func Example() {
	n := nexus.New("https://maven.java.net", credentials.None)

	// obtaining all repositories in Nexus
	repositories, err := n.Repositories()
	if err != nil {
		fmt.Printf("%v: %v", reflect.TypeOf(err), err)
		return
	}

{'fraction_non_alphanumeric': 0.16460513796384396, 'fraction_numerical': 0.003805899143672693, 'mean_word_length': 4.394871794871795, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2793398', 'n_tokens_mistral': 433, 'n_tokens_neox': 407, 'n_words': 75}