Giter VIP home page Giter VIP logo

extracttypetofilediagnostic's People

Watchers

 avatar  avatar  avatar

extracttypetofilediagnostic's Issues

Support extracting types to existing files

If a fix extracts a type into an existing file, the type should be integrated in a clean way.
If the namespace exists, put it in it.
Otherwise create the namespace declaration and put the type in it.
Also handle nested namespaces.
Non-existing using directives should be added.

Document should stay open after renaming a file

Due to the fact, that we remove and add a document when we want to rename it, Visual Studio closes the document. I couldn't find a way to cleanly rename a file. I tried to add a document with the same id, but VS doesn't seem to like that because it crashed. I also tried to use solution.Workspace.OpenDocument(documentId) as a work-around, but nothing happened.

Unify common test code

There are a lot of repeating code segments which decrease maintainability.

  • Use NUnit's parameterized tests to create test data or
  • Extract common code segments into helper methods and use them from within the tests.

The first option is currently preferred as the basic structure is always the same:

  • Setup solution
  • Get diagnostics and compare with expected
  • Apply fixes and compare resulting solution with expected solution
  • Get diagnostics and assert there are none.

Support renaming a file

When there's only a single non-nested type within a file, the result should be a simple rename of the file.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.