Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify documentation code snippet(s) (unclear where static imported methods come from) #6597

Closed
kdvolder opened this issue Mar 7, 2019 · 0 comments
Assignees
Labels
in: docs An issue in Documentation or samples type: enhancement A general enhancement
Milestone

Comments

@kdvolder
Copy link
Member

kdvolder commented Mar 7, 2019

Working with the documentation and trying to get something compiling can be pretty painful when code samples in docs do not include imports. This especially so when statically imported methods are being imported.

This is the section in the docs I'm particularly fighting with at the moment:

https://docs.spring.io/spring-security/site/docs/current/reference/html/test-webflux.html

    @Before
    public void setup() {
        this.rest = WebTestClient
            .bindToApplicationContext(this.context)
            // add Spring Security test Support
            .apply(springSecurity())
            .configureClient()
            .filter(basicAuthentication())
            .build();
    }

Where are the methods 'springSecurity()' and 'basicAuthentication()' defined?

I appreciate the desire to keep the snippets focussed and leave out 'unnecessary cruft'. But I think imports are rather crucial when you want to copy paste sample code from the docs and get it to compile properly.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label May 7, 2019
@jzheaux jzheaux added in: docs An issue in Documentation or samples type: enhancement A general enhancement and removed status: waiting-for-triage An issue we've not yet triaged labels Apr 10, 2023
@marcusdacoregio marcusdacoregio self-assigned this Apr 11, 2023
@marcusdacoregio marcusdacoregio added this to the 5.7.8 milestone Apr 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: docs An issue in Documentation or samples type: enhancement A general enhancement
Projects
Status: Done
Development

No branches or pull requests

4 participants